Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

./build.sh all 报错 #22

Open
h77626592 opened this issue Dec 8, 2021 · 9 comments
Open

./build.sh all 报错 #22

h77626592 opened this issue Dec 8, 2021 · 9 comments

Comments

@h77626592
Copy link

h77626592 commented Dec 8, 2021

您好,在执行 ./build.sh all 操作时遇到以下错误,请求帮助,谢谢

#node -v
v16.13.1
#npm -v
8.1.2

`WARNING in ./node_modules/_@[email protected]@@angular/core/ivy_ngcc/fesm2015/core.js 42527:19-40
System.import() is deprecated and will be removed soon. Use import() instead.
For more info visit https://webpack.js.org/guides/code-splitting/
@ ./src/main.ts 15:0-47 20:4-18
@ multi ./src/main.ts

WARNING in ./node_modules/_@[email protected]@@angular/core/ivy_ngcc/fesm2015/core.js 42554:19-106
System.import() is deprecated and will be removed soon. Use import() instead.
For more info visit https://webpack.js.org/guides/code-splitting/
@ ./src/main.ts 15:0-47 20:4-18
@ multi ./src/main.ts

[email protected] build
ng build --prod --base-href /app/

ERROR in node_modules/@types/node/assert.d.ts:2:68 - error TS1144: '{' or ';' expected.

2 function assert(value: any, message?: string | Error): asserts value;
~~~~~
node_modules/@types/node/assert.d.ts:53:68 - error TS1144: '{' or ';' expected.

53 function ok(value: any, message?: string | Error): asserts value;
~~~~~
node_modules/@types/node/assert.d.ts:62:94 - error TS1144: '{' or ';' expected.

62 function strictEqual(actual: any, expected: T, message?: string | Error): asserts actual is T;
~~~~~~
node_modules/@types/node/assert.d.ts:62:101 - error TS1005: ';' expected.

62 function strictEqual(actual: any, expected: T, message?: string | Error): asserts actual is T;
~~
node_modules/@types/node/assert.d.ts:62:104 - error TS1005: ';' expected.

62 function strictEqual(actual: any, expected: T, message?: string | Error): asserts actual is T;
~
node_modules/@types/node/assert.d.ts:64:98 - error TS1144: '{' or ';' expected.

64 function deepStrictEqual(actual: any, expected: T, message?: string | Error): asserts actual is T;
~~~~~~
node_modules/@types/node/assert.d.ts:64:105 - error TS1005: ';' expected.

64 function deepStrictEqual(actual: any, expected: T, message?: string | Error): asserts actual is T;
~~
node_modules/@types/node/assert.d.ts:64:108 - error TS1005: ';' expected.

64 function deepStrictEqual(actual: any, expected: T, message?: string | Error): asserts actual is T;
~
node_modules/@types/node/assert.d.ts:72:47 - error TS1144: '{' or ';' expected.

72 function ifError(value: any): asserts value is null | undefined;
~~~~~
node_modules/@types/node/assert.d.ts:72:53 - error TS1005: ';' expected.

72 function ifError(value: any): asserts value is null | undefined;
~~
node_modules/@types/node/assert.d.ts:72:56 - error TS1005: ';' expected.

72 function ifError(value: any): asserts value is null | undefined;
~~~~
node_modules/@types/node/assert.d.ts:99:61 - error TS1005: ';' expected.

99 (value: any, message?: string | Error): asserts value;
`

@h77626592
Copy link
Author

哪位大佬知道怎么解决 ?

@GuiTom
Copy link

GuiTom commented Dec 11, 2021

俺也一样!

@GuiTom
Copy link

GuiTom commented Dec 11, 2021

有人能看一下吗?这个问题困扰好多天了@!

@h77626592
Copy link
Author

@linewei @wistingcn @alzee 您好,是否麻烦看下什么问题导致的? npm版本更换过也不行报相同的错误,谢谢

@wistingcn
Copy link
Owner

看看操作系统及版本 @h77626592

@h77626592
Copy link
Author

Ubuntu 18.04 LTS
Linux 11111 4.15.0-118-generic #119-Ubuntu SMP Tue Sep 8 12:30:01 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux @wistingcn

@rcrwhyg
Copy link

rcrwhyg commented May 17, 2022

问题解决了吗?
Linux rcrwhyg 5.4.0-109-generic #123~18.04.1-Ubuntu SMP Fri Apr 8 09:48:52 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
node version:v17.0.1
npm version:8.10.0

@songguang-2010
Copy link

您好,在执行 ./build.sh all 操作时遇到以下错误,请求帮助,谢谢

#node -v v16.13.1 #npm -v 8.1.2

`WARNING in ./node_modules/_@[email protected]@@angular/core/ivy_ngcc/fesm2015/core.js 42527:19-40 System.import() is deprecated and will be removed soon. Use import() instead. For more info visit https://webpack.js.org/guides/code-splitting/ @ ./src/main.ts 15:0-47 20:4-18 @ multi ./src/main.ts

WARNING in ./node_modules/_@[email protected]@@angular/core/ivy_ngcc/fesm2015/core.js 42554:19-106 System.import() is deprecated and will be removed soon. Use import() instead. For more info visit https://webpack.js.org/guides/code-splitting/ @ ./src/main.ts 15:0-47 20:4-18 @ multi ./src/main.ts

[email protected] build
ng build --prod --base-href /app/

ERROR in node_modules/@types/node/assert.d.ts:2:68 - error TS1144: '{' or ';' expected.

2 function assert(value: any, message?: string | Error): asserts value; ~~~~~ node_modules/@types/node/assert.d.ts:53:68 - error TS1144: '{' or ';' expected.

53 function ok(value: any, message?: string | Error): asserts value; ~~~~~ node_modules/@types/node/assert.d.ts:62:94 - error TS1144: '{' or ';' expected.

62 function strictEqual(actual: any, expected: T, message?: string | Error): asserts actual is T; ~~~~~~ node_modules/@types/node/assert.d.ts:62:101 - error TS1005: ';' expected.

62 function strictEqual(actual: any, expected: T, message?: string | Error): asserts actual is T; ~~ node_modules/@types/node/assert.d.ts:62:104 - error TS1005: ';' expected.

62 function strictEqual(actual: any, expected: T, message?: string | Error): asserts actual is T; ~ node_modules/@types/node/assert.d.ts:64:98 - error TS1144: '{' or ';' expected.

64 function deepStrictEqual(actual: any, expected: T, message?: string | Error): asserts actual is T; ~~~~~~ node_modules/@types/node/assert.d.ts:64:105 - error TS1005: ';' expected.

64 function deepStrictEqual(actual: any, expected: T, message?: string | Error): asserts actual is T; ~~ node_modules/@types/node/assert.d.ts:64:108 - error TS1005: ';' expected.

64 function deepStrictEqual(actual: any, expected: T, message?: string | Error): asserts actual is T; ~ node_modules/@types/node/assert.d.ts:72:47 - error TS1144: '{' or ';' expected.

72 function ifError(value: any): asserts value is null | undefined; ~~~~~ node_modules/@types/node/assert.d.ts:72:53 - error TS1005: ';' expected.

72 function ifError(value: any): asserts value is null | undefined; ~~ node_modules/@types/node/assert.d.ts:72:56 - error TS1005: ';' expected.

72 function ifError(value: any): asserts value is null | undefined; ~~~~ node_modules/@types/node/assert.d.ts:99:61 - error TS1005: ';' expected.

99 (value: any, message?: string | Error): asserts value; `

修改app下的package.json文件,锁定@types/node版本

@sunxiaolou
Copy link

哪位大佬知道怎么解决 ?
请问如何解决的?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants