My Angular project utilizes a file that includes several import()
statements to load SVG files using the file-loader
webpack plugin.
Following the migration to Angular 8, I encountered an issue where the angular build process was generating multiple build files in the /dist
folder for each import()
statement, supporting both es5 and es2015.
This particular file is responsible for exporting SVGs to create a dynamic icon component. The original file contains numerous imports.
For example:
https://i.sstatic.net/xF2fC.png
The above source file generates a file for each import()
statement after the build process, like this:
https://i.sstatic.net/u7vlY.png
This issue is causing a proliferation of files, resulting in longer build times for our continuous integration process. Do you have any suggestions to address this problem?