Can you guys suggest me how to add local js files in application
I have tried by adding the local JS file path in index.html like below
<script src="thirdpartyscripts/amcharts.js"></script>
Here **thirdpartyscripts** is my directory.
but getting the error like below.
Error
Copy this folder and file in your target/www folder. Or alternatively use webpack to do this for you in webpack.commons.js. Look at the last line I have added
new CopyWebpackPlugin([
{ from: './node_modules/core-js/client/shim.min.js', to: 'core-js-shim.min.js' },
{ from: './node_modules/swagger-ui/dist', to: 'swagger-ui/dist' },
{ from: './src/main/webapp/swagger-ui/', to: 'swagger-ui' },
{ from: './src/main/webapp/favicon.ico', to: 'favicon.ico' },
{ from: './src/main/webapp/manifest.webapp', to: 'manifest.webapp' },
// { from: './src/main/webapp/sw.js', to: 'sw.js' },
{ from: './src/main/webapp/robots.txt', to: 'robots.txt' },
{ from: './src/main/webapp/thirdparty/sth.js', to: 'thirdparty/sth.js' }
]),
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With