create-egg 4.1.0-beta.34 → 4.1.0-beta.35

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.
Files changed (25) hide show
  1. package/dist/cli.js +1 -1
  2. package/dist/index.js +1 -1
  3. package/dist/{src-BgL2uwim.js → src-C5hWB9Dq.js} +1 -1
  4. package/dist/templates/egg3-simple-ts/test/app/controller/home.test.ts +1 -0
  5. package/dist/templates/egg3-simple-ts/test/app/service/Test.test.ts +1 -0
  6. package/dist/templates/egg3-simple-ts/tsconfig.json +1 -1
  7. package/dist/templates/egg3-tegg/app/module/bar/controller/home.ts +1 -1
  8. package/dist/templates/egg3-tegg/app/module/bar/controller/user.ts +1 -1
  9. package/dist/templates/egg3-tegg/app/module/foo/service/HelloService.ts +1 -1
  10. package/dist/templates/egg3-tegg/package.json +1 -1
  11. package/dist/templates/egg3-tegg/test/app/module/foo/service/HelloService.test.ts +1 -2
  12. package/dist/templates/egg3-tegg/tsconfig.json +2 -3
  13. package/dist/templates/simple-ts/package.json +1 -1
  14. package/dist/templates/simple-ts/test/app/controller/home.test.ts +1 -2
  15. package/dist/templates/simple-ts/test/app/service/Test.test.ts +1 -2
  16. package/dist/templates/simple-ts/tsconfig.json +1 -2
  17. package/dist/templates/tegg/app/module/bar/controller/home.ts +1 -1
  18. package/dist/templates/tegg/app/module/bar/controller/user.ts +1 -0
  19. package/dist/templates/tegg/app/module/foo/service/HelloService.ts +1 -1
  20. package/dist/templates/tegg/package.json +2 -2
  21. package/dist/templates/tegg/test/app/module/bar/controller/home.test.ts +1 -1
  22. package/dist/templates/tegg/test/app/module/bar/controller/user.test.ts +1 -1
  23. package/dist/templates/tegg/test/app/module/foo/service/HelloService.test.skip.ts +1 -1
  24. package/dist/templates/tegg/tsconfig.json +1 -2
  25. package/package.json +3 -3
package/dist/cli.js CHANGED
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import { t as init } from "./src-BgL2uwim.js";
2
+ import { t as init } from "./src-C5hWB9Dq.js";
3
3
 
4
4
  //#region src/cli.ts
5
5
  init().catch((err) => {
package/dist/index.js CHANGED
@@ -1,3 +1,3 @@
1
- import { t as init } from "./src-BgL2uwim.js";
1
+ import { t as init } from "./src-C5hWB9Dq.js";
2
2
 
3
3
  export { init };
@@ -1,8 +1,8 @@
1
1
  import fs from "node:fs";
2
2
  import path from "node:path";
3
+ import * as prompts from "@clack/prompts";
3
4
  import spawn from "cross-spawn";
4
5
  import mri from "mri";
5
- import * as prompts from "@clack/prompts";
6
6
  import colors from "picocolors";
7
7
 
8
8
  //#region src/index.ts
@@ -1,4 +1,5 @@
1
1
  import assert from 'assert';
2
+
2
3
  import { app } from 'egg-mock/bootstrap';
3
4
 
4
5
  describe('test/app/controller/home.test.ts', () => {
@@ -1,4 +1,5 @@
1
1
  import assert from 'assert';
2
+
2
3
  import { Context } from 'egg';
3
4
  import { app } from 'egg-mock/bootstrap';
4
5
 
@@ -1,4 +1,4 @@
1
1
  {
2
2
  "extends": "@eggjs/tsconfig",
3
- "exclude": ["app/public", "app/views", "node_modules*"]
3
+ "exclude": ["app/public", "app/views", "node_modules"]
4
4
  }
@@ -1,5 +1,5 @@
1
- import { EggLogger } from 'egg';
2
1
  import { Inject, HTTPController, HTTPMethod, HTTPMethodEnum } from '@eggjs/tegg';
2
+ import { EggLogger } from 'egg';
3
3
 
4
4
  @HTTPController({
5
5
  path: '/',
@@ -1,5 +1,5 @@
1
- import { Inject, HTTPController, HTTPMethod, HTTPMethodEnum, HTTPQuery } from '@eggjs/tegg';
2
1
  import { HelloService } from '@/module/foo';
2
+ import { Inject, HTTPController, HTTPMethod, HTTPMethodEnum, HTTPQuery } from '@eggjs/tegg';
3
3
 
4
4
  @HTTPController({
5
5
  path: '/bar',
@@ -1,5 +1,5 @@
1
- import { EggLogger } from 'egg';
2
1
  import { SingletonProto, AccessLevel, Inject } from '@eggjs/tegg';
2
+ import { EggLogger } from 'egg';
3
3
 
4
4
  @SingletonProto({
5
5
  // 如果需要在上层使用,需要把 accessLevel 显示声明为 public
@@ -38,7 +38,7 @@
38
38
  "@types/mocha": "10",
39
39
  "@types/node": "24",
40
40
  "oxlint": "1",
41
- "oxlint-tsgolint": "^0.3.0",
41
+ "oxlint-tsgolint": "^0.8.0",
42
42
  "typescript": "5"
43
43
  },
44
44
  "engines": {
@@ -1,8 +1,7 @@
1
1
  import { strict as assert } from 'node:assert';
2
2
 
3
- import { app } from 'egg-mock/bootstrap';
4
-
5
3
  import { HelloService } from '@/module/foo/service/HelloService';
4
+ import { app } from 'egg-mock/bootstrap';
6
5
 
7
6
  describe('test/app/module/foo/service/HelloService.test.ts', () => {
8
7
  it('should hello() work', async () => {
@@ -6,8 +6,7 @@
6
6
  "moduleResolution": "NodeNext",
7
7
  "declaration": false,
8
8
  "paths": {
9
- "@/module/*": ["app/module/*"]
10
- },
11
- "baseUrl": "."
9
+ "@/module/*": ["./app/module/*"]
10
+ }
12
11
  }
13
12
  }
@@ -32,7 +32,7 @@
32
32
  "@eggjs/tsconfig": "beta",
33
33
  "@types/node": "24",
34
34
  "oxlint": "1",
35
- "oxlint-tsgolint": "^0.3.0",
35
+ "oxlint-tsgolint": "^0.8.0",
36
36
  "typescript": "5",
37
37
  "vitest": "beta"
38
38
  },
@@ -1,6 +1,5 @@
1
- import { test, expect } from 'vitest';
2
-
3
1
  import { app } from '@eggjs/mock/bootstrap';
2
+ import { test, expect } from 'vitest';
4
3
 
5
4
  test('should GET / status 200', async () => {
6
5
  const res = await app.httpRequest().get('/').expect(200);
@@ -1,6 +1,5 @@
1
- import { test, expect } from 'vitest';
2
-
3
1
  import { app } from '@eggjs/mock/bootstrap';
2
+ import { test, expect } from 'vitest';
4
3
 
5
4
  test('sayHi should return hi, egg', async () => {
6
5
  const ctx = app.mockContext();
@@ -4,7 +4,6 @@
4
4
  "target": "ES2022",
5
5
  "module": "NodeNext",
6
6
  "moduleResolution": "NodeNext",
7
- "declaration": false,
8
- "baseUrl": "."
7
+ "declaration": false
9
8
  }
10
9
  }
@@ -1,5 +1,5 @@
1
- import type { EggLogger } from 'egg';
2
1
  import { Inject, HTTPController, HTTPMethod, HTTPMethodEnum } from '@eggjs/tegg';
2
+ import type { EggLogger } from 'egg';
3
3
 
4
4
  @HTTPController({
5
5
  path: '/',
@@ -1,4 +1,5 @@
1
1
  import { Inject, HTTPController, HTTPMethod, HTTPMethodEnum, HTTPQuery } from '@eggjs/tegg';
2
+
2
3
  import { HelloService } from '../../foo/index.ts';
3
4
 
4
5
  @HTTPController({
@@ -1,5 +1,5 @@
1
- import type { EggLogger } from 'egg';
2
1
  import { SingletonProto, AccessLevel, Inject } from '@eggjs/tegg';
2
+ import type { EggLogger } from 'egg';
3
3
 
4
4
  @SingletonProto({
5
5
  // 如果需要在上层使用,需要把 accessLevel 显示声明为 public
@@ -29,11 +29,11 @@
29
29
  "@eggjs/bin": "beta",
30
30
  "@eggjs/mock": "beta",
31
31
  "@eggjs/tsconfig": "beta",
32
- "@oxc-node/core": "^0.0.32",
32
+ "@oxc-node/core": "^0.0.35",
33
33
  "@types/node": "24",
34
34
  "cross-env": "10",
35
35
  "oxlint": "1",
36
- "oxlint-tsgolint": "^0.3.0",
36
+ "oxlint-tsgolint": "^0.8.0",
37
37
  "typescript": "5",
38
38
  "vitest": "4",
39
39
  "@vitest/coverage-v8": "4"
@@ -1,5 +1,5 @@
1
- import { test, expect } from 'vitest';
2
1
  import { app } from '@eggjs/mock/bootstrap';
2
+ import { test, expect } from 'vitest';
3
3
 
4
4
  test('should GET / status 200', async () => {
5
5
  const res = await app.httpRequest().get('/');
@@ -1,5 +1,5 @@
1
- import { test, expect } from 'vitest';
2
1
  import { app } from '@eggjs/mock/bootstrap';
2
+ import { test, expect } from 'vitest';
3
3
 
4
4
  test('should GET /bar/user status 200', async () => {
5
5
  const res = await app.httpRequest().get('/bar/user').query({ userId: '20170901' });
@@ -1,5 +1,5 @@
1
- import { test, expect } from 'vitest';
2
1
  import { app } from '@eggjs/mock/bootstrap';
2
+ import { test, expect } from 'vitest';
3
3
 
4
4
  import { HelloService } from '../../../../../app/module/foo/index.ts';
5
5
 
@@ -4,7 +4,6 @@
4
4
  "target": "ES2022",
5
5
  "module": "NodeNext",
6
6
  "moduleResolution": "NodeNext",
7
- "declaration": false,
8
- "baseUrl": "."
7
+ "declaration": false
9
8
  }
10
9
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-egg",
3
- "version": "4.1.0-beta.34",
3
+ "version": "4.1.0-beta.35",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -9,14 +9,14 @@
9
9
  "devDependencies": {
10
10
  "@types/cross-spawn": "^6.0.6",
11
11
  "execa": "^9.6.0",
12
- "tsdown": "0.15.11"
12
+ "tsdown": "^0.17.0"
13
13
  },
14
14
  "engines": {
15
15
  "node": ">=20.19.0"
16
16
  },
17
17
  "repository": {
18
18
  "type": "git",
19
- "url": "git://github.com/eggjs/egg.git",
19
+ "url": "git+https://github.com/eggjs/egg.git",
20
20
  "directory": "tools/create-egg"
21
21
  },
22
22
  "bugs": {