@qlover/create-app 0.1.12 → 0.1.14

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/package.json CHANGED
@@ -1,20 +1,18 @@
1
1
  {
2
2
  "name": "@qlover/create-app",
3
- "version": "0.1.12",
3
+ "version": "0.1.14",
4
4
  "type": "module",
5
5
  "private": false,
6
- "main": "./dist/es/index.js",
7
- "module": "./dist/es/index.js",
8
- "types": "./dist/es/index.d.ts",
6
+ "main": "./dist/index.cjs",
7
+ "module": "./dist/index.js",
8
+ "types": "./dist/index.d.ts",
9
9
  "exports": {
10
+ "./package.json": "./package.json",
10
11
  ".": {
11
- "import": "./dist/es/index.js",
12
- "require": "./dist/cjs/index.js",
13
- "types": "./dist/es/index.d.ts"
14
- },
15
- "./cjs/*": "./dist/cjs/*",
16
- "./es/*": "./dist/es/*",
17
- "./package.json": "./package.json"
12
+ "types": "./dist/index.d.ts",
13
+ "import": "./dist/index.js",
14
+ "require": "./dist/index.cjs"
15
+ }
18
16
  },
19
17
  "files": [
20
18
  "dist",
@@ -26,11 +24,10 @@
26
24
  "CHANGELOG.md"
27
25
  ],
28
26
  "bin": {
29
- "create-app": "./bin/create-app.js"
27
+ "create-app": "bin/create-app.js"
30
28
  },
31
29
  "scripts": {
32
30
  "build": "rollup -c",
33
- "test": "jest",
34
31
  "create:app:build": "npm run build && npm run create:app",
35
32
  "create:app": "node ./bin/create-app.js"
36
33
  },
@@ -50,12 +47,16 @@
50
47
  "publishConfig": {
51
48
  "access": "public"
52
49
  },
50
+ "devDependencies": {
51
+ "@qlover/env-loader": "^0.0.1"
52
+ },
53
53
  "dependencies": {
54
- "@qlover/fe-utils": "latest",
55
- "@qlover/scripts-context": "latest",
54
+ "@qlover/fe-corekit": "^1.2.2",
55
+ "@qlover/scripts-context": "^0.0.8",
56
56
  "commander": "^13.1.0",
57
57
  "ignore": "^7.0.3",
58
58
  "inquirer": "^12.3.2",
59
- "ora": "^8.1.1"
59
+ "ora": "^8.1.1",
60
+ "lodash": "^4.17.21"
60
61
  }
61
62
  }
@@ -10,7 +10,7 @@ function programArgs() {
10
10
  'Do not touch or write anything, but show the commands'
11
11
  )
12
12
  .option('-V, --verbose', 'Show more information')
13
- .option('-n, --name <name>', 'The name of the test')
13
+ .option('-n, --name <name>', 'The name of the test');
14
14
  // parse arguments
15
15
  program.parse();
16
16
 
@@ -46,8 +46,8 @@
46
46
  "run:command": "node bin/test.js"
47
47
  },
48
48
  "devDependencies": {
49
- "@qlover/env-loader": "latest",
50
- "@qlover/fe-standard": "latest",
49
+ "@qlover/env-loader": "workspace:*",
50
+ "@qlover/fe-standard": "workspace:*",
51
51
  "@qlover/scripts-context": "latest",
52
52
  "@release-it/conventional-changelog": "^8.0.1",
53
53
  "@rollup/plugin-commonjs": "^28.0.1",
@@ -9,7 +9,7 @@ import { readFileSync, rmSync } from 'fs';
9
9
  import { Env } from '@qlover/env-loader';
10
10
 
11
11
  const pkg = JSON.parse(readFileSync('./package.json'), 'utf-8');
12
- const env = Env.searchEnv({ logger: console });
12
+ const env = Env.searchEnv();
13
13
  const isProduction = env.get('NODE_ENV') === 'production';
14
14
  const buildDir = 'dist';
15
15
 
@@ -44,7 +44,6 @@ function createPlugin(minify) {
44
44
 
45
45
  function cleanBuildDir() {
46
46
  rmSync(buildDir, { recursive: true, force: true });
47
- console.log(`${buildDir} cleaned`);
48
47
  }
49
48
 
50
49
  cleanBuildDir();
@@ -31,7 +31,7 @@
31
31
  },
32
32
  "devDependencies": {
33
33
  "@qlover/fe-scripts": "latest",
34
- "@qlover/fe-standard": "latest",
34
+ "@qlover/fe-standard": "workspace:*",
35
35
  "@qlover/fe-utils": "latest",
36
36
  "@qlover/fe-release": "latest",
37
37
  "@rollup/plugin-commonjs": "^28.0.1",
@@ -0,0 +1,24 @@
1
+ NODE_ENV=local
2
+
3
+ # ci
4
+ NPM_TOKEN=
5
+ GITHUB_TOKEN=
6
+
7
+ # fe-scripts
8
+ FE_RELEASE_BRANCH=master
9
+ FE_RELEASE=false
10
+ FE_RELEASE_ENV=production
11
+
12
+ # ===== build
13
+ VITE_PUBLIC_PATH=
14
+ VITE_SERVER_PORT=3200
15
+
16
+ # ===== app config
17
+ VITE_USER_TOKEN_STORAGE_KEY=fe_user_token
18
+ VITE_OPEN_AI_MODELS='["gpt-4o-mini","gpt-3.5-turbo","gpt-3.5-turbo-2","gpt-4","gpt-4-32k"]'
19
+ VITE_OPEN_AI_BASE_URL=https://openai-proxy.brain.loocaa.com:1443/v1/
20
+ VITE_OPEN_AI_TOKEN=DlJYSkMVj1x4zoe8jZnjvxfHG6z5yGxK
21
+ VITE_OPEN_AI_TOKEN_PREFIX=Bearer
22
+ VITE_OPEN_AI_REQUIRE_TOKEN=true
23
+ VITE_LOGIN_USER=admin
24
+ VITE_LOGIN_PASSWORD=123456
@@ -48,15 +48,19 @@ export type LoadProps = {
48
48
  Provider?: React.ComponentType<PropsWithChildren<RouteMeta>>;
49
49
  };
50
50
 
51
-
52
- type ComponentValue = React.ComponentType<unknown> | LazyExoticComponent<React.ComponentType<unknown>>;
51
+ type ComponentValue =
52
+ | React.ComponentType<unknown>
53
+ | LazyExoticComponent<React.ComponentType<unknown>>;
53
54
 
54
55
  export type ComponentMaps = {
55
56
  /**
56
57
  * key: ./xxx/bbb.(jsx,js,tsx,ts)
57
58
  */
58
- [key: string]: ComponentValue | (() => Promise<ComponentValue>) | (() => ComponentValue);
59
- }
59
+ [key: string]:
60
+ | ComponentValue
61
+ | (() => Promise<ComponentValue>)
62
+ | (() => ComponentValue);
63
+ };
60
64
 
61
65
  // new RouterManager({
62
66
  // routes: [],
@@ -11,7 +11,7 @@ type RouteComponentType<T = unknown> =
11
11
  export type RouteConfigValue = Omit<RouteObject, 'element' | 'children'> & {
12
12
  /**
13
13
  * 路径
14
- *
14
+ *
15
15
  * FIXME: support `ReactNode`
16
16
  */
17
17
  element?: string;