@botim/botim-cli 0.1.6 → 0.1.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli.js +3 -3
- package/dist/cli.mjs +2 -2
- package/package.json +2 -3
- package/dist/templates/templates/react/README.md +0 -48
- package/dist/templates/templates/react/docs/code-patterns.md +0 -139
- package/dist/templates/templates/react/docs/core-rules.md +0 -69
- package/dist/templates/templates/react/docs/figma-workflow.md +0 -81
- package/dist/templates/templates/react/docs/validation.md +0 -59
- package/dist/templates/templates/react/eslint.config.ts +0 -57
- package/dist/templates/templates/react/index.html +0 -12
- package/dist/templates/templates/react/package-lock.json +0 -12197
- package/dist/templates/templates/react/package.json +0 -102
- package/dist/templates/templates/react/scripts/setup.sh +0 -304
- package/dist/templates/templates/react/src/api/http-client.ts +0 -8
- package/dist/templates/templates/react/src/api/modules/example.ts +0 -12
- package/dist/templates/templates/react/src/app.tsx +0 -27
- package/dist/templates/templates/react/src/components/not-found-content/index.ts +0 -2
- package/dist/templates/templates/react/src/components/not-found-content/not-found-content.tsx +0 -24
- package/dist/templates/templates/react/src/components/welcome-card/index.ts +0 -1
- package/dist/templates/templates/react/src/components/welcome-card/welcome-card.tsx +0 -10
- package/dist/templates/templates/react/src/hooks/use-document-title.ts +0 -11
- package/dist/templates/templates/react/src/i18n/index.ts +0 -40
- package/dist/templates/templates/react/src/i18n/languages/en.json +0 -10
- package/dist/templates/templates/react/src/main.tsx +0 -27
- package/dist/templates/templates/react/src/modules/common/README.md +0 -7
- package/dist/templates/templates/react/src/modules/common/constants.ts +0 -3
- package/dist/templates/templates/react/src/modules/core/README.md +0 -7
- package/dist/templates/templates/react/src/modules/core/api/error.ts +0 -6
- package/dist/templates/templates/react/src/modules/core/app-providers.tsx +0 -18
- package/dist/templates/templates/react/src/modules/core/index.ts +0 -2
- package/dist/templates/templates/react/src/pages/home/index.tsx +0 -13
- package/dist/templates/templates/react/src/pages/not-found/index.tsx +0 -7
- package/dist/templates/templates/react/src/routes.tsx +0 -18
- package/dist/templates/templates/react/src/stores/home-store.ts +0 -11
- package/dist/templates/templates/react/src/styles/font.css +0 -1
- package/dist/templates/templates/react/src/styles/global-style.tsx +0 -27
- package/dist/templates/templates/react/src/styles/tailwind.css +0 -4
- package/dist/templates/templates/react/src/styles/utility-classes.ts +0 -13
- package/dist/templates/templates/react/src/theme/index.tsx +0 -24
- package/dist/templates/templates/react/src/theme/types.ts +0 -10
- package/dist/templates/templates/react/src/types/global.d.ts +0 -139
- package/dist/templates/templates/react/src/types/shims-global.d.ts +0 -97
- package/dist/templates/templates/react/src/utils/currency.ts +0 -6
- package/dist/templates/templates/react/src/utils/date.ts +0 -5
- package/dist/templates/templates/react/src/utils/guard.ts +0 -4
- package/dist/templates/templates/react/src/vite-env.d.ts +0 -1
- package/dist/templates/templates/react/tsconfig.json +0 -39
- package/dist/templates/templates/react/tsconfig.node.json +0 -11
- package/dist/templates/templates/react/types/global.d.ts +0 -131
- package/dist/templates/templates/react/vite.config.ts +0 -179
- package/dist/templates/templates/vue/README.md +0 -19
- package/dist/templates/templates/vue/eslint.config.ts +0 -44
- package/dist/templates/templates/vue/index.html +0 -12
- package/dist/templates/templates/vue/package-lock.json +0 -5774
- package/dist/templates/templates/vue/package.json +0 -39
- package/dist/templates/templates/vue/src/api/http-client.ts +0 -11
- package/dist/templates/templates/vue/src/api/modules/example.ts +0 -12
- package/dist/templates/templates/vue/src/app.vue +0 -23
- package/dist/templates/templates/vue/src/components/card/index.vue +0 -14
- package/dist/templates/templates/vue/src/components/layout/index.ts +0 -1
- package/dist/templates/templates/vue/src/components/layout/page-layout.vue +0 -43
- package/dist/templates/templates/vue/src/components/layout/styles.ts +0 -5
- package/dist/templates/templates/vue/src/components/typography/heading.vue +0 -21
- package/dist/templates/templates/vue/src/components/typography/index.ts +0 -1
- package/dist/templates/templates/vue/src/hooks/use-document-title.ts +0 -23
- package/dist/templates/templates/vue/src/i18n/index.ts +0 -31
- package/dist/templates/templates/vue/src/i18n/languages/en.json +0 -10
- package/dist/templates/templates/vue/src/main.ts +0 -12
- package/dist/templates/templates/vue/src/modules/common/README.md +0 -7
- package/dist/templates/templates/vue/src/modules/common/constants.ts +0 -3
- package/dist/templates/templates/vue/src/modules/core/README.md +0 -7
- package/dist/templates/templates/vue/src/modules/core/api/error.ts +0 -6
- package/dist/templates/templates/vue/src/modules/core/app-providers.ts +0 -17
- package/dist/templates/templates/vue/src/modules/core/index.ts +0 -2
- package/dist/templates/templates/vue/src/pages/home/index.vue +0 -28
- package/dist/templates/templates/vue/src/pages/not-found/index.vue +0 -13
- package/dist/templates/templates/vue/src/routes.ts +0 -19
- package/dist/templates/templates/vue/src/stores/home-store.ts +0 -12
- package/dist/templates/templates/vue/src/styles/font.css +0 -1
- package/dist/templates/templates/vue/src/styles/global-style.ts +0 -63
- package/dist/templates/templates/vue/src/styles/utility-classes.ts +0 -1
- package/dist/templates/templates/vue/src/theme/index.ts +0 -33
- package/dist/templates/templates/vue/src/theme/types.ts +0 -10
- package/dist/templates/templates/vue/src/types/global.d.ts +0 -9
- package/dist/templates/templates/vue/src/utils/currency.ts +0 -6
- package/dist/templates/templates/vue/src/utils/date.ts +0 -5
- package/dist/templates/templates/vue/src/utils/guard.ts +0 -4
- package/dist/templates/templates/vue/src/vite-env.d.ts +0 -1
- package/dist/templates/templates/vue/tsconfig.json +0 -36
- package/dist/templates/templates/vue/tsconfig.node.json +0 -9
- package/dist/templates/templates/vue/types/global.d.ts +0 -7
- package/dist/templates/templates/vue/vite.config.ts +0 -74
|
@@ -1,74 +0,0 @@
|
|
|
1
|
-
import vue from '@vitejs/plugin-vue';
|
|
2
|
-
import { defineConfig } from 'vite';
|
|
3
|
-
import tsconfigPaths from 'vite-tsconfig-paths';
|
|
4
|
-
import path from 'node:path';
|
|
5
|
-
import fs from 'node:fs';
|
|
6
|
-
|
|
7
|
-
// Plugin to resolve @* imports to src/*
|
|
8
|
-
const resolveAtAliases = () => ({
|
|
9
|
-
name: 'resolve-at-aliases',
|
|
10
|
-
resolveId(id: string) {
|
|
11
|
-
if (id.startsWith('@') && !id.startsWith('@/')) {
|
|
12
|
-
const match = id.match(/^@([^/]+)(.*)$/);
|
|
13
|
-
if (match) {
|
|
14
|
-
const [, alias, rest] = match;
|
|
15
|
-
const basePath = path.resolve(__dirname, `./src/${alias}${rest}`);
|
|
16
|
-
|
|
17
|
-
// Check if path already has an extension
|
|
18
|
-
const hasExtension = /\.(ts|vue|js|tsx|jsx|json)$/i.test(rest);
|
|
19
|
-
if (hasExtension) {
|
|
20
|
-
// Path already has extension, check if file exists
|
|
21
|
-
try {
|
|
22
|
-
if (fs.existsSync(basePath) && fs.statSync(basePath).isFile()) {
|
|
23
|
-
return basePath;
|
|
24
|
-
}
|
|
25
|
-
} catch {
|
|
26
|
-
// File doesn't exist or error occurred
|
|
27
|
-
}
|
|
28
|
-
} else {
|
|
29
|
-
// Try to resolve with common extensions
|
|
30
|
-
const extensions = ['.ts', '.vue', '.js', '.tsx', '.jsx'];
|
|
31
|
-
for (const ext of extensions) {
|
|
32
|
-
const fullPath = basePath + ext;
|
|
33
|
-
try {
|
|
34
|
-
if (fs.existsSync(fullPath) && fs.statSync(fullPath).isFile()) {
|
|
35
|
-
return fullPath;
|
|
36
|
-
}
|
|
37
|
-
} catch {
|
|
38
|
-
// Continue to next extension
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
// If no file found, try directory with index files
|
|
44
|
-
try {
|
|
45
|
-
if (fs.existsSync(basePath) && fs.statSync(basePath).isDirectory()) {
|
|
46
|
-
const extensions = ['.ts', '.vue', '.js', '.tsx', '.jsx'];
|
|
47
|
-
for (const ext of extensions) {
|
|
48
|
-
const indexPath = path.join(basePath, `index${ext}`);
|
|
49
|
-
if (fs.existsSync(indexPath) && fs.statSync(indexPath).isFile()) {
|
|
50
|
-
return indexPath;
|
|
51
|
-
}
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
} catch {
|
|
55
|
-
// Continue
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
// Return null to let Vite's default resolver handle it
|
|
59
|
-
return null;
|
|
60
|
-
}
|
|
61
|
-
}
|
|
62
|
-
return null;
|
|
63
|
-
}
|
|
64
|
-
});
|
|
65
|
-
|
|
66
|
-
export default defineConfig(() => ({
|
|
67
|
-
plugins: [ vue(), tsconfigPaths(), resolveAtAliases() ],
|
|
68
|
-
server: {
|
|
69
|
-
port: 5174
|
|
70
|
-
},
|
|
71
|
-
build: {
|
|
72
|
-
sourcemap: true
|
|
73
|
-
}
|
|
74
|
-
}));
|