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
Upgrade to Angular 9 #11262
Upgrade to Angular 9 #11262
Conversation
generators/client/templates/angular/webpack/webpack.common.js.ejs
Outdated
Show resolved
Hide resolved
I couldn't use TestBed.inject instead of TestBed.get because we use mock classes instead of the real service so the typing is not working. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I reviewed the code but did not test the newer changes locally. There is a CI issue related to entity screens. I also restarted the CI due to an npm/cloudflare issue (E429 too many requests) which should be fixed now.
...ors/client/templates/angular/src/main/webapp/app/layouts/navbar/active-menu.directive.ts.ejs
Show resolved
Hide resolved
Thanks @ruddell ! Hope that's good, I tested it on my laptop with some entities... Let's see if the CI is ok 🙏 |
FYI, the CI failed during the packaging phase here |
I need a release after jhipster/ng-jhipster#124 is merged and we should - finally - be good 🎉 |
It’s missing tsconfig-aot.json cleanup. |
@mshima No I think I removed it, where do you see it ? |
I wasn’t clear. The file should be removed from old projects. |
It was an error in my tsconfig file. And the second thing I've noticed you have |
@postpersonality alright i'll check this out, thanks for reaching up |
There is also
during the I think But doing that leads to
|
Looks like 9.0.3 is not ready : angular/angular#35709 |
Thanks for posting this. Got the same problem with the 9.0.3. The 9.0.2 works fine for me. |
@postpersonality I don't have the TS warnings. Did you add |
I think this is ready for merge. |
@wmarques, I will try to have a quick pass by today evening or tomorrow. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall code looks good. I have provided few minor comments.
generators/client/templates/angular/src/main/webapp/app/polyfills.ts.ejs
Show resolved
Hide resolved
@@ -16,6 +16,7 @@ | |||
See the License for the specific language governing permissions and | |||
limitations under the License. | |||
-%> | |||
import './polyfills'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
any specific reason to move to this approach or can we follow cli generated code to add it to tsconfig.app.json
like
"files": ["src/main.ts", "src/polyfills.ts"],
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just thought it reduce entry points, I don't see why we put the polyfills apart...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you confirm that it still produces a different bundle for polyfills? If not, then, it's a deviation from current behavior and also wouldn't recommend that.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@wmarques, can you confirm the behavior?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It doesn't produces a different bundle but the polyfill would still be loaded so for me that's not really important, polyfills are always loaded, we don't do differential loading like angular CLI does.
In my schematic sample project, I had noticed lint errors/warnings with |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! I would like to see Angular 9.0.4 if possible.
"@angular/localize": "^9.0.0", | ||
"@angular/platform-browser": "9.0.0", | ||
"@angular/platform-browser-dynamic": "9.0.0", | ||
"@angular/router": "9.0.0", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Angular 9.0.4 is available https://github.com/angular/angular/releases.
I'm assigning a bug bounty to this one because it wasn't that straightforward and it's an important feature for JHipster. |
generators/client/templates/angular/src/main/webapp/app/polyfills.ts.ejs
Outdated
Show resolved
Hide resolved
@mraible : there is already a bounty on the issue, but if you think it's not enough, I'm increasing it and remove the bounty on the PR. No need to add bounty on both issue and PR, it can confuse people :p |
Thanks @mraible and @vishal423, should be good now 😄 (if the CI god is with me 🙏) |
Only one React build failing 😢 |
Didn't notice anything with |
Bounty claimed https://opencollective.com/generator-jhipster/expenses/14646 |
Fix #11255
Please make sure the below checklist is followed for Pull Requests.
All continuous integration 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