- This topic has 11 replies, 6 voices, and was last updated 5 years, 9 months ago by support-swapna.
-
AuthorPosts
-
StéphaneParticipantHello,
I would like to create a project mixing angular and Java in a webapp. I know it’s possible to do with le Maven frontend-maven-plugin: https://github.com/eirslett/frontend-maven-plugin
But the plugin use a different structure of the project: the package.json file can’t be at the root of the project. How to change the package.json location with CodeMix ?
Thank you.
Regards,
Stef
Wojciech GalanciakParticipantHi Stephane,
CodeMix does not have any constraints for package.json location. Of course we do use a default one in our project wizards as those are mostly dedicated to web applications. It is possible to, e.g. put an angular app inside a frontend folder in your project.
If I miss something then please provide some more details about an exact scenario when CodeMix does not behave as expected.
Kind regards,
Wojciech Galanciak
StéphaneParticipantHi Wojciech,
What is the good practice if I want to import this project https://github.com/daggerok/frontend-maven-plugin-example/ ?
Finally I imported it with CodeMix. I imported it with “Maven existing projects” and after I imported “Angular project” selecting the folder with the package.json. Is it correct ? It’s strange for me to have 2 projects in my workspace when one project in inner the second project.
Regards,
Stef
jhugohrMemberHey Stephane,
can you please provide a screen shot of your projects final structure after the import? We would like to see what is your scenario to provide you with the right directions.
Best Regards,
Hugo Herrera.
StéphaneParticipantHi,
I did this video. You will see I can’t add the angular project of the Maven module because the OK button is disabled:
Regards,
Stef
StéphaneParticipantSorry, I made a mistake during the video try to create the angular project when I wanted to import it. I will create another video.
StéphaneParticipantHi,
Here, the video showing how I’m importing the angular project from the Maven module using frontend-maven-plugin. It’s working fine:
https://www.youtube.com/watch?v=871UqYZtudw
And now a video showing I can’t create an angular project inside the Maven module with CodeMix because the button is disabled.
Regards,
Stef
support-tonyKeymasterStef,
Thanks for the video.
I notice, in the second video, that you are trying to use the New>Angular Project wizard. This is why the Finish button was not available (the Angular project already exists). However, as the Angular project already exists, you should be using the Import wizard. Go to File>Import>Angular>Angular Project and then browse to, and select, the location of the existing source for the project, fill in the Node.js and Npm versions that you want to use and click Finish.
This will create a separate workspace project, so you will be able to see the source in both the new project and the original project. However it’s possible to configure the project explorer to see the Angular project in the parent project. Click the View Menu icon in the Project Explorer toolbar and then select “Filters and Customization”. In the
Filters
tab, select theNested Projects: hide folders when project is shown as nested
option. In theContent
tab selectNested Projects
then click OK. You should now see the project appearing as a separate node undersrc\main
, in the parent project and as a separate project in its own right.Please let us know how you get on with this or if you have further questions.
StéphaneParticipantHi Tony,
In the second video in my post #605325, I’m creating a new Angular project in the Maven module. The js folder is empty (i renamed the previous js to js.old). But CodeMix can’t enable the Finish button.
Regards,
Stef
Aaron LaraMemberStef,
I double checked your video and replicated the issue at my end. It turns out there is indeed a bug in our logic for when selecting a non default location. I will raise a request for the dev team to work on this and I will let you know when a fix is available.
As a workaround, if you want to create a project at a non default location you can try this:
1. Create a new Angular project by using default location
2. Delete the project from the workspace using the project explorer view but do not remove files from disk.
3. Move the project to the desired location by using your system’s files explorer. (You might need to close Eclipse first as the directory might get locked)
4. Import it by using our import wizardimport > Angular Project
.Sorry for the inconveniences caused and thanks for reporting this issue!
Cheers!
Aaron Lara
StéphaneParticipantHello Aaron,
I followed your workaround and it worked fine.
Thank you very much !
Regards,
Stef
support-swapnaModeratorStef,
Our latest CodeMix 3 release is out and we have added support for creating Angular projects in a non default location. Please update and let us know if you see any issues.
–Swapna
Genuitec Support -
AuthorPosts