English 中文(简体)
Error: Optimization error [scripts.[contenthash:20].js]: Error: Terser failed for unknown reason
原标题:
  • 时间:2022-10-24 14:44:06
  •  标签:
  • angular
  • npm

I have this error when I build my Angular app:

Error description image

问题回答

check in your angular.json if you are not calling an empty .js file in scripts

Following up on Gatos reply, I was able to get a successful build after removing

"scripts": ["src/assets/js/pay-with-amazon.min.js"],

From my build > options in angular.json.

I would start by removing your scripts one by one and attempting a build after each removal to figure out the culprit and then determine how to resolve the issue from there.

Good luck.

making sure you do not have any unused files in "scripts": in the angular.json should resolve this issue.





相关问题
Angular matSort not working on Date column by desc

Trying to sort the material table with date column , date format is MM/DD/YYYY ,h:mm A , order of date is not by latest date and time. Anything which i missed from the below stackblitz code. https:/...

热门标签