I had implemented a project using jhipster . Initially i was using JWT authentication. We built our project using this. But now the requirement changed and we want to use OAuth2 Authentication. I build a new jhipster project and choose OAuth2 Authentication and tried to compare it with our existing project but the changes are huge. Can anyone suggest me how can i solve this problem.
The changes should not be huge unless you compare code generated by 2 different versions of JHipster.
Make sure you use same version of JHipster as when you generated your project and change authenticationType in the .yo-rc.json file in your project folder, run jhipster in your existing project folder, compare changes with git.
Related
I have got some work to modify default html generated by Jhipster for Angular2 more specifically,i want to modify styles for grid generated by Jhipster for Entity's.
I have gone through tutorial creating module in Jhispter documentation.
https://jhipster.github.io/modules/creating-a-module/
generator for creating subgenerator is also their can someone please give me pointers on this problem?
e.g
yo jhipster:entity Author
from above command jhipster creates all necessary files at server and client like JPA Entity,REST controller,Service, at client side it creates CRUD UI for Author entity using Angular2(i opted for anular2)
I want to modify client generation Code, i just want to modify HTML templates which gets generated by jhipster entity sub:generator
you need to run Yarn and start modifying your author.component.html
which will automatically refreshed in your Browser.
https://jhipster.github.io/development/
You could also consider using git prior to running the generator and then reverting the server side code once the generator has ran
In order to present a brand new way of developing a web application, our team decided to create an Angular 2 web application that will be integrated within an already existing Maven Project in Eclipse Mars which DOES NOT use NodeJS nor Angular.
We are currently using the frontend-maven-plugin belonging to com.github.eirslet and managed to download and install both node.exe and npm.
Now, here is the deal: our web application has its own package.json file with all the configuration required to run properly, BUT we would like to be able to differentiate between the web applications, as each one of them belongs to a different working directory (i.e. com.webapp.app01, com.webapp.app02, ...).
As the plugin does not let the user use the npm install command on different directories, we were wondering about how we could reach this goal... maybe using a general package.json, but generating all .js and dependency files in each project directories.
Would that be something even possible?
Could you give us some help?
Thank you.
Cheers!
What I would suggest is to have a multi-module maven project, with a common parent, and children, that would give you this kind of architecture:
parent-project
|-child-project1 (java project)
|-child-project2 (webapp1)
|-child-project3 (webapp2)
|....
|-child-projectn (webapp n-1)
This way you can have for each web-app the frontend plugin available. And you can handle the flow of the build from the parent project (for instance if webapp2 needs to be built before webapp1, you can orchestrate it from the parent)
We decided to generate all the libraries locally and upload them to SVN, due to the fact that the already existing structure cannot be changed and the maven plugin is too much limited for our purpose.
Thank you for your replies, though. :-)
I've been developing a JHipster app for a number of days and I realize now that it was initially created without the Social login option. What is the best approach for adding it after the fact? Can I simply add "enableSocialSignIn": true to .yo-rc.json and re-run yo jhipster (everything is checked into git), or are the changes too significant?
Rather than clobber my app, I ended up creating a new temporary JHipster app, doing a diff of the two apps, and selectively copying over only the code that pertained to social logic (and eliminating the code that pertained to OAuth2, since I also switched to session based / spring security authentication as well).
I have an existing JHipster application that was generated without adding the websocket option. A need has come about for this functionality to be added to the application for a realtime data view, is there a way to bolt this functionality into my existing generated app?
I tried adding toggling on the websocket: false value in the .yml file and re-running yo jhipster but this did not add in any new files and the example user tracker was not added into the project so assuming this cannot be accomplished this way
Thanks
The generator is looking for settings in the .yo-rc.json file which is located at root level in the folder of your app. Depending on your IDE it can be that is not shown and you need to show it over otehr perspective or to view it in a terminal/cmd.
In the .yo-rc.json you will need to change the value of the websocket property from no to spring-websocket i.e.
"websocket": "spring-websocket",
Now when you run your generator it should generate the parts need it for websockets. Also have a look at the jhipster doc for websockets
I just found swagger-node and I have installed all of the dependencies.
Now I have a REST express api at /var/www/myApi this has already been created but needs documentation.
However no where in the documentation does it state how to use an already existing project with swagger.
I am able to create a new project and run it, but how do I use an existing project?