- [x ] bug report -> please search issues before submitting
- [ ] feature request
_ _ ____ _ ___
/ \ _ __ __ _ _ _| | __ _ _ __ / ___| | |_ _|
/ △ \ | '_ \ / _` | | | | |/ _` | '__| | | | | | |
/ ___ \| | | | (_| | |_| | | (_| | | | |___| |___ | |
/_/ \_\_| |_|\__, |\__,_|_|\__,_|_| \____|_____|___|
|___/
@angular/cli: 1.5.0-beta.1
node: 6.10.3
os: win32 x64
@angular/animations: 5.0.0-rc.2
@angular/cdk: 2.0.0-beta.12
@angular/common: 5.0.0-rc.2
@angular/compiler: 5.0.0-rc.2
@angular/compiler-cli: 5.0.0-rc.2
@angular/core: 5.0.0-rc.2
@angular/forms: 5.0.0-rc.2
@angular/http: 5.0.0-rc.2
@angular/material: 2.0.0-beta.12
@angular/platform-browser: 5.0.0-rc.2
@angular/platform-browser-dynamic: 5.0.0-rc.2
@angular/platform-server: 5.0.0-rc.2
@angular/router: 5.0.0-rc.2
@angular/cli: 1.5.0-beta.1
@angular/language-service: 5.0.0-rc.2
typescript: 2.5.3
Angular Cli 1.5.0-beta.1
ng build --aot && ng build --prod
ng build works fine
Running the 1.4.7 gives no errors.
> ng build --prod
Date: 2017-10-15T14:23:01.412Z
Hash: 733c77181e79f09e63b1
Time: 49654ms
chunk {0} styles.48dc33ba103b17efb308.bundle.css (styles) 563 kB {3} [initial] [rendered]
chunk {1} polyfills.3bc34265385d52184eab.bundle.js (polyfills) 86 bytes {3} [initial] [rendered]
chunk {2} main.e402deade8b026b7d50e.bundle.js (main) 84 bytes [initial] [rendered]
chunk {3} inline.c4a92da1d0d88e20b804.bundle.js (inline) 1.45 kB [entry] [rendered]
ERROR in error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/es6/reflect.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/es7/reflect.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_a-function.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_an-instance.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_an-object.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_array-from-iterable.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_array-includes.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_array-methods.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_array-species-constructor.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_array-species-create.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_bind.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_classof.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_cof.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_collection-strong.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_collection-weak.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_collection.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_core.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_ctx.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_defined.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_descriptors.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_dom-create.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_enum-bug-keys.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_export.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_fails.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_for-of.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_global.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_has.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_hide.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_html.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_ie8-dom-define.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_inherit-if-required.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_invoke.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_iobject.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_is-array-iter.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_is-array.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_is-object.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_iter-call.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_iter-create.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_iter-define.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_iter-detect.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_iter-step.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_iterators.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_library.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_meta.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_metadata.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_object-assign.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_object-create.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_object-dp.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_object-dps.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_object-gopd.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_object-gopn.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_object-gops.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_object-gpo.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_object-keys-internal.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_object-keys.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_object-pie.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_own-keys.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_property-desc.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_redefine-all.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_redefine.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_set-proto.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_set-species.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_set-to-string-tag.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_shared-key.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_shared.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_to-absolute-index.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_to-integer.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_to-iobject.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_to-length.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_to-object.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_to-primitive.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_uid.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_validate-collection.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/_wks.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/core.get-iterator-method.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es6.map.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es6.reflect.apply.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es6.reflect.construct.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es6.reflect.define-property.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es6.reflect.delete-property.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es6.reflect.enumerate.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es6.reflect.get-own-property-descriptor.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es6.reflect.get-prototype-of.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es6.reflect.get.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es6.reflect.has.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es6.reflect.is-extensible.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es6.reflect.own-keys.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es6.reflect.prevent-extensions.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es6.reflect.set-prototype-of.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es6.reflect.set.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es6.set.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es6.weak-map.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es7.reflect.define-metadata.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es7.reflect.delete-metadata.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es7.reflect.get-metadata-keys.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es7.reflect.get-metadata.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es7.reflect.get-own-metadata-keys.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es7.reflect.get-own-metadata.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es7.reflect.has-metadata.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es7.reflect.has-own-metadata.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/core-js/modules/es7.reflect.metadata.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/util/node_modules/inherits/inherits.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/util/support/isBuffer.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/util/util.js' because it would overwrite input file.
error TS5055: Cannot write file 'C:/proj/proj/node_modules/zone.js/dist/zone.js' because it would overwrite input file.
npm ERR! Windows_NT 10.0.15063
npm ERR! argv "C:\\NodeJS\\node.exe" "C:\\NodeJS\\node_modules\\npm\\bin\\npm-cli.js" "run" "build"
npm ERR! node v6.10.3
npm ERR! npm v3.10.10
npm ERR! code ELIFECYCLE
npm ERR! [email protected] prebuild: `ng build --prod`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] prebuild script 'ng build --prod'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the proj package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! ng build --prod
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs proj
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls proj
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! C:\proj\proj\npm-debug.log
"dependencies": {
"@agm/core": "^1.0.0-beta.1",
"@angular/animations": "^5.0.0-rc.2",
"@angular/cdk": "^2.0.0-beta.8",
"@angular/common": "^5.0.0-rc.2",
"@angular/compiler": "^5.0.0-rc.2",
"@angular/compiler-cli": "^5.0.0-rc.2",
"@angular/core": "^5.0.0-rc.2",
"@angular/forms": "^5.0.0-rc.2",
"@angular/http": "^5.0.0-rc.2",
"@angular/material": "^2.0.0-beta.8",
"@angular/platform-browser": "^5.0.0-rc.2",
"@angular/platform-browser-dynamic": "^5.0.0-rc.2",
"@angular/platform-server": "^5.0.0-rc.2",
"@angular/router": "^5.0.0-rc.2",
"@nguniversal/express-engine": "^5.0.0-beta.1",
"@nguniversal/module-map-ngfactory-loader": "^5.0.0-beta.1",
"aws-sdk": "^2.90.0",
"bcrypt-nodejs": "0.0.3",
"body-parser": "^1.17.2",
"chart.js": "^2.5.0",
"compression": "^1.7.0",
"connect-flash": "^0.1.1",
"connect-gzip-static": "^2.0.1",
"connect-redis": "^3.3.0",
"core-js": "^2.5.1",
"cron": "^1.2.1",
"ejs": "^2.5.6",
"email-templates": "^2.6.0",
"enum": "^2.4.0",
"express": "^4.15.3",
"express-session": "^1.15.4",
"font-awesome": "^4.7.0",
"geo-tz": "^3.3.3",
"hammerjs": "^2.0.8",
"html": "^1.0.0",
"html-pdf": "^2.1.0",
"jimp": "^0.2.28",
"moment": "^2.18.1",
"mongoose": "^4.11.4",
"mongoose-auto-increment": "^5.0.1",
"mongoose-history": "^0.4.2",
"morgan": "^1.8.2",
"multer": "^1.3.0",
"ngx-cookie": "^1.0.0",
"ngx-quill": "^1.3.5",
"nodemailer": "^4.0.1",
"nodemailer-sendgrid-transport": "^0.2.0",
"owasp-password-strength-test": "^1.3.0",
"passport": "^0.3.2",
"passport-local-mongoose": "^4.0.0",
"pathinfo": "^0.1.0",
"rand-token": "^0.3.0",
"reflect-metadata": "^0.1.10",
"rxjs": "^5.4.2",
"sanitize-html": "^1.14.1",
"serve-favicon": "^2.4.3",
"socket.io": "^2.0.3",
"stripe": "^4.23.1",
"transliteration": "^1.6.2",
"v8-profiler": "^5.7.0",
"validator": "^8.0.0",
"x-frame-options": "^1.0.0",
"zone.js": "^0.8.14"
},
"devDependencies": {
"@angular/cli": "1.5.0-beta.1",
"@angular/language-service": "^5.0.0-rc.2",
"@types/jasmine": "~2.5.53",
"@types/jasminewd2": "~2.0.2",
"@types/node": "~6.0.60",
"angular2-template-loader": "^0.6.2",
"codelyzer": "~3.1.1",
"jasmine-core": "~2.6.2",
"jasmine-spec-reporter": "~4.1.0",
"karma": "~1.7.0",
"karma-chrome-launcher": "~2.1.1",
"karma-cli": "~1.0.1",
"karma-coverage-istanbul-reporter": "^1.2.1",
"karma-jasmine": "~1.1.0",
"karma-jasmine-html-reporter": "^0.2.2",
"nodemon": "^1.11.0",
"protractor": "~5.1.2",
"ts-loader": "^2.3.2",
"ts-node": "~3.2.0",
"tslint": "~5.3.2",
"typescript": "^2.5.3",
"webpack-node-externals": "^1.6.0"
}
This bug popped up after updating to beta.1.
Also tried the latest build rc.0 but no luck.
Building with 1.4.7 gives no errors
Heya, I tried running a brand new project with Angular CLI 1.5.0-rc.1 and Angular packages at 5.0.0-rc.2 and I could not get this error when doing ng build --aot.
Can you setup a minimal repro please? You can read here why this is needed. A good way to make a minimal repro is to create a new app via ng new repro-app and adding the minimum possible code to show the problem. Then you can push this repository to github and link it here.
I have the same error when switching from AotPlugin to AngularCompilerPlugin in a custom webpack build with 5.0.0-rc.2. Seems to be caused by allowJS: true in tsconfig.
package.json
{
"name": "acp-jserrors",
"devDependencies": {
"@angular/compiler-cli": "5.0.0-rc.2",
"@angular/language-service": "5.0.0-rc.2",
"@ngtools/webpack": "1.8.0-rc.0",
"typescript": "2.5",
"webpack": "3.6"
},
"dependencies": {
"@angular/compiler": "5.0.0-rc.2",
"@angular/core": "5.0.0-rc.2",
"core-js": "2.5.1",
"rxjs": "^5.4.3"
}
}
tsconfig.json
{
"compilerOptions": {
"target": "es5",
"module": "esnext",
"moduleResolution": "node",
"lib": ["dom", "es2015"],
"allowJs": true,
"experimentalDecorators": true,
"outDir": "target/tsc",
"baseUrl": "/"
},
"angularCompilerOptions": {
"entryModule": "./app#AppModule",
"genDir": "target/aot",
"basePath": "/"
},
"include": ["*.ts"],
"exclude": [
"node_modules",
"target"
]
}
webpack.config.js
const webpack = require("webpack");
const path = require("path");
const { AngularCompilerPlugin } = require("@ngtools/webpack");
module.exports = {
context: __dirname,
entry: {
main: "./app"
},
output: {
path: path.join(__dirname, "target"),
filename: "out.js"
},
module: {
rules: [{
test: /\.ts$/,
loader: "@ngtools/webpack"
}]
},
plugins: [
new AngularCompilerPlugin({
tsConfigPath: path.join(__dirname, "tsconfig.json")
})
]
};
app.ts
import {NgModule} from "@angular/core";
import "core-js/es6/array";
@NgModule({})
export class AppModule {}
I can see this happening with allowJs, and have opened an issue in the main angular repo: https://github.com/angular/angular/issues/19757
Thank you @jbedard This fixed my problem 👍
Hey everyone! I had this problem and I think I figured out a way around it (possibly partly due to an Angular update).
To start:
5.1).4.*, as of the time of the writing -- not 5.*)allowJs: true in your config file.Run ng serve --aot or ng build --watch=auto --aot You should see the above error and be unable to access your site.
Open one of the .ts file that's part of your app and make a small change (such as adding a single space) and then save the file.
Your app should compile!
(The --watch=auto and --aot flags are critical for this workaround, as far as I can tell)
Hi I have a same issue while including jsplumb which is a external npm js. Ref Stack overflow
With the first build without any configuration to tsconfig.json I get the following error.
ERROR in src/app/jsplumb/jsplumb.component.ts(4,25): error TS6143: Module '../../../node_modules/jsplumb/dist/js/jsplumb.js' was resolved to 'D:/myproj/angular5/myapp/node_modules/jsplumb/dist/js/jsplumb.js', but '--allowJs' is not set.
With "allowJs":true in the tsconfig.json get the following error
ERROR in error TS5055: Cannot write file 'D:/myproj/angular5/myapp/node_modules/jsplumb/dist/js/jsplumb.js' because it would overwrite input file.
Adding a tsconfig.json file will help organize projects that contain both TypeScript and JavaScript files. Learn more at https://aka.ms/tsconfig.
As per tsconfig FAQ
Why am I getting the error TS5055: Cannot write file 'xxx.js' because it would overwrite input file.
with an outDir ("outDir": "./dist/out-tsc") this issue should be resolved. This is already set in my tsconfig.
If we add noEmit to true it simply builds the application, not including any js we get a blank white screen.
Let me know if anyone has tried to include external js with new angular cli and face the same kind of error and what is the solution for the same.
Without any additional option added to tsconfig.json if I try to modify any ts file the application will compile with success and I am able to work. But this does not help while running ng build, to create a deployable binary.
HI @ameya,
If you're looking for a workaround when running ng build, please see my above post. Basically, you can run ng build --prod --watch=auto and then make a change in order to get a production build. That might not help you if you're using a build server to do the building, but it's been helpful to me, as I've been doing my production builds by hand.
Any updates on this issue? I just updated to Angular 5.2.0 / Typescript 2.5.3 and I am still getting the same error. Frustrating. Why has this bug been unassigned?
@shobeck This should be corrected in 1.6.8. As this issue originally references an older beta version, if you are still experiencing this issue with 1.6.8, please open a new issue describing the conditions that exhibit the problem.
I've updated just now to angular/cli 1.6.8.
tsconfig.json
{
"compileOnSave": false,
"compilerOptions": {
"outDir": "./dist/out-tsc",
"outFile": "./dist/out-tsc/bundle",
"sourceMap": true,
"declaration": false,
"module": "system",
"moduleResolution": "node",
"emitDecoratorMetadata": true,
"experimentalDecorators": true,
"target": "es5",
"allowJs": true,
"types": [ "node" ],
"typeRoots": [
"node_modules/@types"
],
"lib": [
"es2017",
"dom"
]
}
}
ERROR in error TS6082: Only 'amd' and 'system' modules are supported alongside --outFile.
It’s fixed, not yet released. Will check if the fix works tomorrow.
Ok...thank you!
[waiting in anticipation...]
Upgrading to 1.6.8 fixed original problem form me :)
This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.
Read more about our automatic conversation locking policy.
_This action has been performed automatically by a bot._
Most helpful comment
I have the same error when switching from
AotPlugintoAngularCompilerPluginin a custom webpack build with 5.0.0-rc.2. Seems to be caused byallowJS: truein tsconfig.package.json
tsconfig.json
webpack.config.js
app.ts