Ionic cordova run [platform] --prod --release throws weird errors


#1

Hi all,

I’ve used jquery module in my app all the way and so far no problem. The problem is triggered when I export application dev to prod version “ionic cordova run [platform] --prod --release”. I’ve got the following error.

typescript error
Cannot write file ‘…/node_modules/jquery/dist/jquery.js’
because it would overwrite input file.

I’ve been googling about solutions the whole day and still can’t get the right one. I’ve pasted my tsconfig.json. I would really appreciate if someone could help me with this one. Thank you!.

{
“compilerOptions”: {
“allowJs”: true,
“allowSyntheticDefaultImports”: true,
“declaration”: false,
“emitDecoratorMetadata”: true,
“experimentalDecorators”: true,
“lib”: [
“dom”,
“es2015”
],
“module”: “es2015”,
“moduleResolution”: “node”,
“sourceMap”: true,
“target”: “es5”
},
“include”: [
“src//*.ts"
],
“exclude”: [
“node_modules”,
"src/
/.spec.ts",
"src/**/tests/
.ts”
],
“compileOnSave”: false,
“atom”: {
“rewriteTsconfig”: false
}
}