STF 有大佬拿过 STF 最新版做二次开发吗,求助

环境搭一半就放弃 · 2019年12月12日 · 最后由 环境搭一半就放弃 回复于 2019年12月12日 · 1433 次阅读

在旧版本的 STF 执行 gulp build,就不会报下面的错,拿最新版的就会,有人知道怎么办吗?
查阅了各种帖子也不知道怎么解决,npm install 其中一些模块也毫无反应!
ERROR in ./res/web_modules/nine-bootstrap/index.js
Module not found: Error: Cannot resolve module 'font-lato-2-subset' in /work/node-v8.16.2-linux-x64/lib/node_modules/stf/res/web_modules/nine-bootstrap
@ ./res/web_modules/nine-bootstrap/index.js 7:0-29

ERROR in ./res/web_modules/nine-bootstrap/index.js
Module not found: Error: Cannot resolve module 'components-font-awesome/css/font-awesome.css' in /work/node-v8.16.2-linux-x64/lib/node_modules/stf/res/web_modules/nine-bootstrap
@ ./res/web_modules/nine-bootstrap/index.js 5:0-55

ERROR in Node Sass does not yet support your current environment: Linux 64-bit with Unsupported runtime (57)
For more information on which environments are supported please see:
https://github.com/sass/node-sass/releases/tag/v3.13.1
@ ./res/web_modules/nine-bootstrap/nine-bootstrap.scss 4:14-133

ERROR in ./res/web_modules/angular-borderlayout/index.js
Module not found: Error: Cannot resolve module 'angular-borderlayout/src/borderLayout.js' in /work/node-v8.16.2-linux-x64/lib/node_modules/stf/res/web_modules/angular-borderlayout
@ ./res/web_modules/angular-borderlayout/index.js 1:0-51

ERROR in ./res/web_modules/angular-borderlayout/index.js
Module not found: Error: Cannot resolve module 'angular-borderlayout/src/borderLayout.css' in /work/node-v8.16.2-linux-x64/lib/node_modules/stf/res/web_modules/angular-borderlayout
@ ./res/web_modules/angular-borderlayout/index.js 2:0-52

ERROR in ./res/web_modules/angular-xeditable/index.js
Module not found: Error: Cannot resolve module 'angular-xeditable/dist/js/xeditable.js' in /work/node-v8.16.2-linux-x64/lib/node_modules/stf/res/web_modules/angular-xeditable
@ ./res/web_modules/angular-xeditable/index.js 1:0-49

ERROR in ./res/web_modules/angular-xeditable/index.js
Module not found: Error: Cannot resolve module 'angular-xeditable/dist/css/xeditable.css' in /work/node-v8.16.2-linux-x64/lib/node_modules/stf/res/web_modules/angular-xeditable
@ ./res/web_modules/angular-xeditable/index.js 2:0-51

ERROR in ./res/app/components/stf/device/device-service.js
Module not found: Error: Cannot resolve module 'oboe' in /work/node-v8.16.2-linux-x64/lib/node_modules/stf/res/app/components/stf/device
@ ./res/app/components/stf/device/device-service.js 1:11-26

ERROR in ./res/app/control-panes/dashboard/clipboard/index.js
Module not found: Error: Cannot resolve module 'angular-elastic' in /work/node-v8.16.2-linux-x64/lib/node_modules/stf/res/app/control-panes/dashboard/clipboard
@ ./res/app/control-panes/dashboard/clipboard/index.js 3:0-26

ERROR in ./res/app/components/stf/common-ui/table/index.js
Module not found: Error: Cannot resolve module 'ng-table/dist/ng-table' in /work/node-v8.16.2-linux-x64/lib/node_modules/stf/res/app/components/stf/common-ui/table
@ ./res/app/components/stf/common-ui/table/index.js 2:0-40

ERROR in ./res/app/components/stf/common-ui/notifications/index.js
Module not found: Error: Cannot resolve module 'angular-animate' in /work/node-v8.16.2-linux-x64/lib/node_modules/stf/res/app/components/stf/common-ui/notifications
@ ./res/app/components/stf/common-ui/notifications/index.js 1:0-26

ERROR in ./res/app/components/stf/common-ui/enable-autofill/index.js
Module not found: Error: Cannot resolve module 'angular-cookies' in /work/node-v8.16.2-linux-x64/lib/node_modules/stf/res/app/components/stf/common-ui/enable-autofill
@ ./res/app/components/stf/common-ui/enable-autofill/index.js 1:0-26

ERROR in ./res/web_modules/ng-context-menu/index.js
Module not found: Error: Cannot resolve module 'ng-context-menu/dist/ng-context-menu' in /work/node-v8.16.2-linux-x64/lib/node_modules/stf/res/web_modules/ng-context-menu
@ ./res/web_modules/ng-context-menu/index.js 1:0-47

ERROR in ./res/app/components/stf/angular-packery/index.js
Module not found: Error: Cannot resolve module 'packery/js/rect.js' in /work/node-v8.16.2-linux-x64/lib/node_modules/stf/res/app/components/stf/angular-packery
@ ./res/app/components/stf/angular-packery/index.js 3:0-29

ERROR in ./res/app/components/stf/angular-packery/index.js
Module not found: Error: Cannot resolve module 'packery/js/packer.js' in /work/node-v8.16.2-linux-x64/lib/node_modules/stf/res/app/components/stf/angular-packery
@ ./res/app/components/stf/angular-packery/index.js 4:0-31

ERROR in ./res/app/components/stf/angular-packery/index.js
Module not found: Error: Cannot resolve module 'packery/js/item.js' in /work/node-v8.16.2-linux-x64/lib/node_modules/stf/res/app/components/stf/angular-packery
@ ./res/app/components/stf/angular-packery/index.js 5:0-29

ERROR in ./res/app/components/stf/angular-packery/index.js
Module not found: Error: Cannot resolve module 'packery/js/packery.js' in /work/node-v8.16.2-linux-x64/lib/node_modules/stf/res/app/components/stf/angular-packery
@ ./res/app/components/stf/angular-packery/index.js 6:14-46

ERROR in ./res/web_modules/ng-file-upload/index.js
Module not found: Error: Cannot resolve module 'ng-file-upload/angular-file-upload-shim' in /work/node-v8.16.2-linux-x64/lib/node_modules/stf/res/web_modules/ng-file-upload
@ ./res/web_modules/ng-file-upload/index.js 1:0-50

ERROR in ./res/web_modules/ng-file-upload/index.js
Module not found: Error: Cannot resolve module 'ng-file-upload/angular-file-upload' in /work/node-v8.16.2-linux-x64/lib/node_modules/stf/res/web_modules/ng-file-upload
@ ./res/web_modules/ng-file-upload/index.js 2:0-45

ERROR in ./res/app/components/stf/logcat/logcat-service.js
Module not found: Error: Cannot resolve module 'underscore.string/index' in /work/node-v8.16.2-linux-x64/lib/node_modules/stf/res/app/components/stf/logcat
@ ./res/app/components/stf/logcat/logcat-service.js 2:9-37

ERROR in ./res/web_modules/epoch/index.js
Module not found: Error: Cannot resolve module 'epoch/dist/css/epoch.min.css' in /work/node-v8.16.2-linux-x64/lib/node_modules/stf/res/web_modules/epoch
@ ./res/web_modules/epoch/index.js 4:0-39

ERROR in ./res/web_modules/epoch/index.js
Module not found: Error: Cannot resolve module 'epoch/dist/js/epoch.min.js' in /work/node-v8.16.2-linux-x64/lib/node_modules/stf/res/web_modules/epoch
@ ./res/web_modules/epoch/index.js 5:0-37

ERROR in ./res/web_modules/epoch/index.js
Module not found: Error: Cannot resolve module 'ng-epoch' in /work/node-v8.16.2-linux-x64/lib/node_modules/stf/res/web_modules/epoch
@ ./res/web_modules/epoch/index.js 6:0-19

如果觉得我的文章对您有用,请随意打赏。您的支持将鼓励我继续创作!
共收到 1 条回复 时间 点赞

我已经自己解决这个问题了!论坛里的大佬说的,我看了,应该是没有一个人说对
首先要说,本人是在 cent7OS 上安装这些的。
stf 的依赖包被分成两个部分,一个是执行 npm install 安装,它是查找 package.json 文件里的依赖包;
还有一个部分是需要执行 bower install 去安装,因为很多大佬使用的 mac 系统,早就执行了 bower install,这些包又对重新打包有强依赖。
另外,npm install 请加上--unsafe-perm, zmq.node 找不到也是因为没有在 npm install 里加上--unsafe-perm

需要 登录 后方可回复, 如果你还没有账号请点击这里 注册