Angular 4: after running the command: ng build
I have this structure
0.chunk.js favicon.ico polyfills.bundle.js.map
0.chunk.js.map index.html scripts.bundle.js
1.chunk.js inline.bundle.js scripts.bundle.js.map
1.chunk.js.map inline.bundle.js.map styles.bundle.js
2.chunk.js main.bundle.js styles.bundle.js.map
2.chunk.js.map main.bundle.js.map vendor.bundle.js
assets polyfills.bundle.js vendor.bundle.js.map
What is the difference between scripts.bundle.js
and vendor.bundle.js
?
I believe that the difference is that it scripts.bundle.js
contains all the external files .js
, but it vendor.bundle.js
contains all the created modules.
EDIT
but I can import files .js
from node_modules
to vendor.bundle.js
and scripts.bundle.js
. What is the best approach: importing files .js
into modules or adding them to an object.angular-cli.json
scripts
~ Thanks so much for the help!
source
share