How troublesome it will be to run the angular project after deployment

  • the front-end project I developed with angular6 compiled the project
    copied to JAVA project webapp below
  • using the command ng build-- prod-- aot .
  • Static resources can be accessed through configuration in the JAVA project of SpringMVC .
    then copy the compiled angular project to
    webapp/a directory
  • visit the home page in the
  • browser: http://localhost:8080/ project name / ng/index.html
    shows the whiteboard. After reading the console prompt that there is a problem with the references of several js files in index.html , then manually modify the path
    and the home page can be opened, but when you click to open other pages, it prompts N multiple errors:
    .
  • I just want to ask that when your compiled angular project is copied to the JAVA project,
    also needs to modify a lot of problems on path references?
    is there any batch solution? Also, can you give me a hint of how to solve the mistakes in the picture above?
Nov.13,2021

angular.json

  

Thank you for your answer, which has been resolved

Menu