1

jHipster: how to generate only entities during jdl import

or entities plus dto and mappers?

jhipster import-jdl jhipster-jdl.jh
Mohsen
  • 4,536
  • 2
  • 27
  • 49
Arthur
  • 1,156
  • 3
  • 20
  • 49
  • Helo, I notice that qualificator --skip-server dont work with latest version of jhipster. I try this framework and analyze his potentiality, but I have problems to separate frontend code by backend for this anomaly. Actually I have same issues, and read you I think that the solution is open a ticket jiira about this. – Alessandro Modica Jun 19 '21 at 11:02

2 Answers2

4

To generate just entities (and skip application JDL generation), you can pass --ignore-application. The full command will look like: jhipster import-jdl jhipster-jdl.jh --ignore-application

If you want DTOs and Mappers, add dto * with mapstruct to the bottom of your JDL. More info in the docs: https://jhipster.tech/jdl/

Jon Ruddell
  • 6,244
  • 1
  • 22
  • 40
  • I wasn't aware of the `--ignore-application` flag, it's wonderful! Without that the import was re-generating all classes, but using it only the new ones or modified are created! Wow thanks! – funder7 Nov 06 '20 at 21:20
3

You can use jhipster entity <entityName> --[options] where options are:

  • --skip-server - This will skip the server-side code and will generate only the client-side code.
  • --skip-client - This will skip the client-side code and will generate only the server-side code.

Check: https://www.jhipster.tech/creating-an-entity/

dori
  • 131
  • 3