Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[angular] Switch to Angular CLI #10624

Merged
merged 1 commit into from
Oct 26, 2020
Merged

Conversation

wmarques
Copy link
Contributor

@wmarques wmarques commented Oct 15, 2019

Fixes #10539

As discussed, given the opportunities offered by the Angular CLI, we can now extend their config with ours so IMO we should move into Angular CLI.

This offers some advantages:

  • Less config files
  • Less dependencies
  • Enjoy the benefits of Angular CLI (further optimisations, differential loading)

We could even go further with the Angular CLI schematics, for example we could do an Entity schematic to generate an entity page.

Still Todo:

  • Compare bundles (check drawbacks)
  • Remove old dependencies / useless files
  • ng test Jest support
  • PWA support
  • Travis tests are green
  • Tests are added where necessary
  • Documentation is added/updated where necessary
  • Coding Rules & Commit Guidelines as per our CONTRIBUTING.md document are followed

@wmarques wmarques changed the title Switch to Angular CLI WIP Switch to Angular CLI Oct 15, 2019
@DanielFran
Copy link
Member

@wmarques Can you fix conflicts?
Would be awesome to have it ready for next release.

@wmarques
Copy link
Contributor Author

@DanielFran I think it will be for the v7, I want to test this well and to check if we don't lost performances

@wmarques wmarques added the v7 label Dec 20, 2019
@@ -60,6 +60,8 @@
"zone.js": "0.10.2"
},
"devDependencies": {
"@angular-builders/custom-webpack": "^8.2.0",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"^8.2.0" => "8.2.0"

@@ -60,6 +60,8 @@
"zone.js": "0.10.2"
},
"devDependencies": {
"@angular-builders/custom-webpack": "^8.2.0",
"@angular-devkit/build-angular": "^0.803.3",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"^0.803.3" => "0.803.3"

@@ -18,4 +18,4 @@
-%>
import 'core-js/proposals/reflect-metadata';
import 'zone.js/dist/zone';
require('../manifest.webapp');
//require('../manifest.webapp');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

so you can remove this line ?

@mraible
Copy link
Contributor

mraible commented Jan 17, 2020

This PR needs a rebase to fix conflicts.

@wmarques
Copy link
Contributor Author

Yep I'll work on it during the month

@CLAassistant
Copy link

CLAassistant commented Apr 20, 2020

CLA assistant check
All committers have signed the CLA.

@pascalgrimaud
Copy link
Member

@wmarques : what is the state of your PR ? The original ticket is opened for too long (8 months)

@@ -18,5 +18,5 @@
-%>
{
"extends": "./tsconfig.json",
"files": ["<%= MAIN_SRC_DIR %>app/app.main.ts"]
"files": ["<%= MAIN_SRC_DIR %>app/app.main.ts","<%= MAIN_SRC_DIR %>app/polyfills.ts"]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"<%= MAIN_SRC_DIR %>app/app.main.ts","<%= MAIN_SRC_DIR %>app/polyfills.ts"
=>
"<%= MAIN_SRC_DIR %>app/app.main.ts", "<%= MAIN_SRC_DIR %>app/polyfills.ts"
😇

@mshima mshima changed the title WIP Switch to Angular CLI [angular] WIP Switch to Angular CLI Aug 29, 2020
@pascalgrimaud pascalgrimaud changed the base branch from master to main October 11, 2020 20:18
@gmarziou gmarziou mentioned this pull request Oct 16, 2020
1 task
Copy link
Member

@mshima mshima left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should webpack.(common|prod|dev).js be removed?

test/utils/expected-files.js Show resolved Hide resolved
generators/client/templates/angular/tsconfig.spec.json.ejs Outdated Show resolved Hide resolved
generators/client/templates/angular/angular.json.ejs Outdated Show resolved Hide resolved
generators/client/templates/angular/angular.json.ejs Outdated Show resolved Hide resolved
generators/client/templates/angular/angular.json.ejs Outdated Show resolved Hide resolved
@wmarques
Copy link
Contributor Author

Thanks alot @mshima for your review ! I'll do this tomorrow in the afternoon, hope we can merge this asap then

@mshima
Copy link
Member

mshima commented Oct 19, 2020

Thanks alot @mshima for your review ! I'll do this tomorrow in the afternoon, hope we can merge this asap then

Saw yesterday that this is almost ready.
Great work.

@mshima
Copy link
Member

mshima commented Oct 20, 2020

@wmarques do you want some help finishing this PR?

@wmarques
Copy link
Contributor Author

No thanks I'll apply your comments tomorrow, I was quite busy today 🙁

@DanielFran
Copy link
Member

@wmarques Can you fix the conflicts.
There is too much changes in main repo, and this PR is almost done and should be merged as soon as you fix last comments 😊

@wmarques
Copy link
Contributor Author

@DanielFran Working on it !

@wmarques
Copy link
Contributor Author

I'll fix this tomorrow, sorry I won't have time tonight 😢

@wmarques wmarques force-pushed the add-angular-cli branch 4 times, most recently from f261ff7 to 3410c88 Compare October 25, 2020 21:26
@pascalgrimaud
Copy link
Member

@wmarques : if the CI is green and if you feel confident, go ahead and merge this. It will avoid some conflict and we can still do post review

test/needle-api/needle-client-webpack.spec.js Outdated Show resolved Hide resolved
test/needle-api/needle-client-webpack.spec.js Outdated Show resolved Hide resolved
@wmarques wmarques changed the title [angular] WIP Switch to Angular CLI [angular] Switch to Angular CLI Oct 25, 2020
@wmarques wmarques merged commit d2f82e3 into jhipster:main Oct 26, 2020
@wmarques wmarques deleted the add-angular-cli branch October 26, 2020 00:27
@wmarques
Copy link
Contributor Author

Finally ! Thanks guys, that was quite a journey 😄
I'll keep an eye on issues and I'll provide some PRs to improve it (like the eslint-plugin as suggested by @kaidohallik)

@kaidohallik
Copy link
Contributor

The final result LGTM, thanks for your hard work @wmarques !

@gmarziou
Copy link
Contributor

gmarziou commented Oct 26, 2020

Great work!

I also think the doc and the generated README.md should be updated.

@wmarques
Copy link
Contributor Author

@gmarziou you're right I'll work on it tonight

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Move back to angular cli
9 participants