试图跟踪循环依赖但无法使
我的应用程序在尝试使用 Node 14.15.0 构建时抛出循环依赖错误和堆栈溢出(在 Node 10.14.1 中构建得很好,目前设置为我的全局默认值)。
无论如何,错误表明我应该
Use node --trace-warnings ...
显示创建警告的位置。
好吧,我已经尝试将该标志添加到我的 package.json 构建脚本中的各个位置以及我正在运行的命令行
npm run build-builder --trace-warnings
,但我仍然收到相同的消息告诉我Use node --trace-warnings ...
显示在哪里警告已创建。
有什么想法吗?
这是我的 package.json 构建脚本块:
"scripts": {
"ng": "ng",
"serve": "node --max_old_space_size=4096 node_modules/@angular/cli/bin/ng serve --port 4400",
"start": "concurrently --kill-others \"npm run db\" \"npm run serve --watch --poll=1000 --hmr=true\"",
"start:ie": "concurrently --kill-others \"npm run dbie\" \"npm run serve --watch --poll=1000 --host=10.0.2.2:4400\"",
"start:aot-dev": "concurrently --kill-others \"npm run db\" \"npm run serve --aot=true --watch --poll=1000\"",
"start:aot-prod": "concurrently --kill-others \"npm run db\" \"npm run serve --prod --aot=true --watch --poll=1000\"",
"build": "ng build",
"build:prod": "node --trace-warnings --max_old_space_size=4096 node_modules/@angular/cli/bin/ng build --prod --aot --base-href --source-map=false",
"build-forms": "run-p clean-sche copy-lib-sass-wait _pre-build-forms",
"_pre-build-forms": "ng build wrux-json-schema-form --prod --watch",
"build-builder": "run-p clean-buil copy-lib-scss-builder-wait _pre-build-builder",
"_pre-build-builder": "ng build wrux-form-builder --prod --watch",
"build-forms-jenkins": "run-p clean-sche copy-lib-sass-wait _pre-build-forms-jenkins",
"_pre-build-forms-jenkins": "ng build wrux-json-schema-form --prod",
"build-builder-jenkins": "run-p clean-buil copy-lib-scss-builder-wait _pre-build-builder-jenkins",
"_pre-build-builder-jenkins": "ng build wrux-form-builder --prod",
"rebuild-projects": "run-s _rebuild-forms _rebuild-builder",
"_rebuild-forms": "run-p clean-sche copy-lib-sass-wait _rebuild-forms-end",
"_rebuild-forms-end": "ng build wrux-json-schema-form --prod",
"_rebuild-builder": "run-p clean-buil copy-lib-scss-builder-wait _rebuild-builder-end",
"_rebuild-builder-end": "ng build wrux-form-builder --prod",
"copy-lib-schemas": "ncp ./projects/wrux-form-builder/src/lib/assets/schemas ./dist/wrux-form-builder/assets/schemas --stopOnErr --clobber=true",
"copy-lib-i18n": "ncp ./projects/wrux-form-builder/src/lib/assets/i18n ./dist/wrux-form-builder/assets/i18n --stopOnErr --clobber=true",
"copy-lib-sass-wait": "wait-on file:./dist/wrux-json-schema-form && npm run copy-lib-sass",
"copy-lib-sass": "run-s mkdir-lib-sass-theme-checkbox copy-lib-sass-theme copy-lib-sass-theme-helpers copy-lib-sass-checkbox copy-lib-sass-theme-layout",
"mkdir-lib-sass-theme-checkbox": "mkdirp ./dist/wrux-json-schema-form/theming/styles/framework-library/wrux-framework/material-checkbox",
"copy-lib-sass-theme": "ncp ./projects/wrux-json-schema-form/src/lib/_styles.theme.scss ./dist/wrux-json-schema-form/theming/styles/_styles.theme.scss --stopOnErr=true --clobber=true --dereference=false",
"copy-lib-sass-theme-helpers": "ncp ./projects/wrux-json-schema-form/src/lib/_styles.helpers.scss ./dist/wrux-json-schema-form/theming/styles/_styles.helpers.scss --stopOnErr=true --clobber=true --dereference=false",
"copy-lib-sass-theme-layout": "ncp ./projects/wrux-json-schema-form/src/lib/_styles.layout.scss ./dist/wrux-json-schema-form/theming/styles/_styles.layout.scss --stopOnErr=true --clobber=true --dereference=false",
"copy-lib-sass-checkbox": "ncp ./projects/wrux-json-schema-form/src/lib/framework-library/wrux-framework/material-checkbox/_material-checkbox.theme.scss ./dist/wrux-json-schema-form/theming/styles/framework-library/wrux-framework/material-checkbox/_material-checkbox.theme.scss --stopOnErr=true --clobber=true --dereference=false",
"copy-lib-scss-builder-wait": "wait-on file:./dist/wrux-form-builder && npm run copy-lib-scss-builder",
"copy-lib-scss-builder": "run-s mkdir-lib-scss-theme-builder copy-lib-scss-builder-theme copy-lib-scss-builder-theme-helpers copy-lib-scss-builder-theme-ngx-reset copy-lib-scss-builder-theme-ngx-theme copy-lib-scss-builder-theme-variables",
"mkdir-lib-scss-theme-builder": "mkdirp ./dist/wrux-form-builder/theming",
"copy-lib-scss-builder-theme": "ncp ./projects/wrux-form-builder/src/lib/theming/_styles.theme.scss ./dist/wrux-form-builder/theming/_styles.theme.scss --stopOnErr=true --clobber=true --dereference=false",
"copy-lib-scss-builder-theme-helpers": "ncp ./projects/wrux-form-builder/src/lib/theming/_styles.helpers.scss ./dist/wrux-form-builder/theming/_styles.helpers.scss --stopOnErr=true --clobber=true --dereference=false",
"copy-lib-scss-builder-theme-ngx-reset": "ncp ./projects/wrux-form-builder/src/lib/theming/_ngx-dnd.reset.scss ./dist/wrux-form-builder/theming/_ngx-dnd.reset.scss --stopOnErr=true --clobber=true --dereference=false",
"copy-lib-scss-builder-theme-ngx-theme": "ncp ./projects/wrux-form-builder/src/lib/theming/_ngx-dnd.theme.scss ./dist/wrux-form-builder/theming/_ngx-dnd.theme.scss --stopOnErr=true --clobber=true --dereference=false",
"copy-lib-scss-builder-theme-variables": "ncp ./projects/wrux-form-builder/src/lib/theming/_variables.scss ./dist/wrux-form-builder/theming/_variables.scss --stopOnErr=true --clobber=true --dereference=false",
"clean-lock": "rimraf ./package-lock.json",
"clean-buil": "rimraf ./dist/wrux-form-builder",
"clean-sche": "rimraf ./dist/wrux-json-schema-form",
"test": "ng test",
"lint": "ng lint",
"e2e": "ng e2e",
"db": "./node_modules/.bin/json-server --watch ./mocks/db.json --port 4100",
"dbie": "./node_modules/.bin/json-server --watch ./mocks/db.json --port 4100 --host 10.0.2.2",
"mocks": "concurrently --kill-others \"npm run db\" \"npm run serve\"",
"mocks:prod": "concurrently --kill-others \"npm run db\" \"npm run serve --prod --aot=true\"",
"mocks:make": "node ./mocks/server.js",
"mocks:dist": "concurrently --kill-others \"npm run db\" \"http-server ./dist\""
},
注意:这个应用程序是作为一个库构建的,并在绑定到 Angular 10.2.x 的项目中使用,所以我无法更新这个应用程序中超过其当前 10.x 的角度版本
回答如下:更多推荐
试图跟踪循环依赖但无法使
发布评论