Questions Management – Frontend – Create frontend Angular project using Angular CLI

On the frontend, Questions Management will use the Angular framework along with some other JavaScript libraries for development. I will also use the frontend-maven-plugin to manage the dependencies for this frontend. In this tutorial, we will be using the Angular CLI to create a new frontend project for our Questions Management application and configure it to use the frontend-maven-plugin.

I have a tutorial that guides you all on how to create a new Angular project using Angular CLI. Every operation is similar, only the project name will be different!

I will create a new Angular project in the folder of our questions-management parent project by running the following command:

Now, check the questions-management parent project directory, you will see the results as follows:

Questions Management - Frontend - Create frontend Angular project using Angular CLI

Would it be more reasonable if we renamed the questions-management folder to your frontend?

Questions Management - Frontend - Create frontend Angular project using Angular CLI

Now if you go to the frontend, run the command “ng serve” and go to http://localhost:4200/ then you will see the following output:

Questions Management - Frontend - Create frontend Angular project using Angular CLI

To apply using the frontend-maven-plugin for our Angular project, I will create a new pom.xml file in this directory.

Questions Management - Frontend - Create frontend Angular project using Angular CLI

Then declare the frontend-maven-plugin plugin as follows:

At this point, if you run “mvn install” and then run “ng serve” then the result stays the same.

Chia sẽ bài viết này ...Share on Facebook
Facebook
0Tweet about this on Twitter
Twitter
Share on LinkedIn
Linkedin

Add Comment