0
votes

I am working on a project generated with Jhipster 2.1.1

When I package with Prod profile, if I check the files that are generated in Dist folder, I only see the files that were generated during the creation of the project (files that were generated by jhipster generator).

All the scripts that were created after the first generation of the project(when I created entities) are not in the dist folder, and the one that have been updated (navbar for example) stay in their original version.

Is it a known issue or something I should configure in my project in order to make the prod package work successfully?

Thank you.

2
This version is no longer supported so I'm afraid you might be on your own here. In prod build, the dist folder should nto contain your original files, it should contain one file that is minified and versioned and is the concatenation of all your files. same thing for your bower dependencies.Gaël Marziou
too bad, I should have asked my question one month ago :) So I need to figure out why grunt doesnt put my html views and js scripts into /dist/xxxxxapp.jsuser1260928

2 Answers

1
votes

I had similar issue and it was due to having unclosed single quotes in custom html files. As a result the grunt task useminPrepare failed.

0
votes

GrantLay is right (& I have upvoted it). However, just to elaborate (as having all this in comments, would look clumsy)

Grunt (ngtemplates task) on angular templates is hanging - if there is an issue with the format of any of the html files.

As GrantLay rightly mentioned - most of the time, the issue is either with the structure of the Html (tags), extra quotes.

ngtemplates would show the errors corresponding to tags - but for those extra quotes it just hangs - without giving a hint w.r.t which file has caused the issue.

So, I tried to verify the issues using htmllint ( https://github.com/htmllint/grunt-htmllint)

But, it gave me so many errors that it is an uphill (& almost impossible) task to go through all those errors.

Then, I have removed other tasks and has just run htmlmin (& yes in verbose mode) htmlmin has stuck at the file which has issue.

May be running htmllint on just that file alone - might eliminate the manual work of going through each line (Somehow, I just took the manual route to find the issue.)