TreeModel已经导出。导出的标识符必须唯一

时间:2019-05-12 03:03:16

标签: angular meteor babel babili

我在Meteor应用程序上使用angular-tree-component,并且在开发模式下都可以正常运行,但是当我尝试编译该应用程序以进行生产时,meteor运行了一个抛出错误的缩小器。

While minifying app code:
packages/minifyStdJS/plugin/minify-js.js:96:26: Babili minification error
within packages/modules.js:
node_modules/angular-tree-component/dist/angular-tree-component.js

`TreeModel` has already been exported. Exported identifiers must be unique.:

export { TreeModel, TreeNode, TreeDraggedElement, TreeVirtualScroll,
TREE_ACTIONS, KEYS, LoadingComponent, TreeComponent, TreeNodeComponent,
TreeNodeContent, TreeDropDirective, TreeDragDirective,
TreeNodeExpanderComponent, TreeNodeChildrenComponent, TreeNodeDropSlot,
TreeNodeCollectionComponent, TreeViewportComponent, TreeNodeCheckboxComponent
};

我已经尝试过angular-tree-component的版本8.2.0和8.3.0

我需要帮助来了解导致此问题的原因,以便为它找到解决方法。

package.json

{
 "scripts": {
    ...
    "app:prod": "meteor run --settings settings.json --production"
    ...
  },
  "dependencies": {
    "@angular/animations": "^7.2.15",
    "@angular/common": "^7.2.15",
    "@angular/compiler": "^7.2.15",
    "@angular/core": "^7.2.15",
    "@angular/forms": "^7.2.15",
    "@angular/http": "^7.2.15",
    "@angular/platform-browser": "^7.2.15",
    "@angular/platform-browser-dynamic": "^7.2.15",
    "@angular/platform-server": "^7.2.15",
    "@angular/router": "^7.2.15",
    "@babel/runtime": "^7.4.4",
    "@ngx-share/core": "^6.0.1",
    "@ngx-translate/core": "^10.0.2",
    "@ngx-translate/http-loader": "^3.0.1",
    "angular-sortablejs": "^2.7.0",
    "angular-tree-component": "^8.2.0",
    "angular2-virtual-scroll": "^0.3.2",
    "at.js": "^1.5.4",
    "bcrypt": "^2.0.1",
    "chart.js": "^2.8.0",
    "core-js": "^2.6.5",
    "favico.js": "^0.3.10",
    "hammerjs": "^2.0.8",
    "html-meta-tags": "^1.0.0",
    "jquery": "^3.4.1",
    "jsonwebtoken": "^8.5.1",
    "ldapauth-fork": "^4.2.0",
    "luminous-lightbox": "^2.3.2",
    "meteor-node-stubs": "^0.4.1",
    "meteor-rxjs": "^0.4.14",
    "moment": "^2.24.0",
    "ng-uikit-pro-standard": "...",
    "ng2-cookies": "^1.0.12",
    "ngx-color-picker": "^6.6.0",
    "node-cache": "^4.2.0",
    "path-to-regexp": "^2.2.1",
    "prerender-node": "^3.2.4",
    "reflect-metadata": "^0.1.13",
    "rxjs": "^6.5.1",
    "smoothscroll-polyfill": "^0.4.4",
    "sortablejs": "^1.9.0",
    "string-to-color": "^2.1.1",
    "timeme.js": "^2.0.3",
    "web-animations-js": "^2.3.1",
    "zone.js": "^0.8.29"
  },
  "devDependencies": {
    "@angular/compiler-cli": "^7.2.15",
    "@types/chai": "^4.1.4",
    "@types/meteor": "^1.4.28",
    "@types/meteor-accounts-phone": "0.0.5",
    "@types/mocha": "^5.2.6",
    "@types/underscore": "^1.8.14",
    "chai": "^4.1.2",
    "chai-spies": "^1.0.0",
    "meteor-typings": "^1.4.1",
    "sinon": "^6.0.1",
    "tslint": "^5.16.0",
    "typescript": "3.2.4"
  },
  "meteor": {
    "mainModule": {
      "client": "client/main.ts",
      "server": "server/main.ts"
    }
  }
}

.meteor/packages

meteor-base@1.4.0             # Packages every Meteor app needs to have
mobile-experience@1.0.5       # Packages for a great mobile UX
mongo@1.6.2                   # The database Meteor supports right now
reactive-var@1.0.11            # Reactive variable for tracker
tracker@1.2.0                 # Meteor's client-side reactive programming library

ecmascript@0.12.4              # Enable ECMAScript2015+ syntax in app code
shell-server@0.4.0            # Server-side component of the `meteor shell` command
bigdata:logs
accounts-facebook@1.3.2
accounts-google@1.3.2
bozhao:link-accounts@2.0.2
force-ssl@1.1.0
percolate:migrations
mixmax:smart-disconnect
service-configuration@1.0.11
angular-compilers
es5-shim@4.8.0
accounts-base@1.4.3
accounts-password@1.5.1
standard-minifiers@1.1.0
server-render@0.3.1
jquery
fortawesome:fontawesome@=4.7.0
froala:editor

我们有一个用于生产的复杂管道,但是在本地npm run app:prod失败

0 个答案:

没有答案