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
Fixes #28270 - consume babel from @theforeman/builder and @theforeman/env #7178
Conversation
Issues: #28270 |
741fc4f
to
7a7f4e4
Compare
Packaging: theforeman/foreman-packaging#4348 |
package.json
Outdated
@@ -34,22 +34,13 @@ | |||
"@storybook/addon-storysource": "^3.4.12", | |||
"@storybook/react": "~3.4.12", | |||
"@storybook/storybook-deployer": "^2.0.0", | |||
"@theforeman/vendor-dev": "^3.0.0", | |||
"@theforeman/env": "^3.1.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.
❤️
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.
Nice! works as expected!
Thanks @sharvit !
Why did you add the redux update commit?
Because I need to use |
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.
Seems to work nicely together with REX and tasks
7a7f4e4
to
1062f27
Compare
package.json
Outdated
@@ -34,22 +34,14 @@ | |||
"@storybook/addon-storysource": "^3.4.12", | |||
"@storybook/react": "~3.4.12", | |||
"@storybook/storybook-deployer": "^2.0.0", | |||
"@theforeman/vendor-dev": "^1.7.0", | |||
"@theforeman/babel": "^3.2.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.
Needs a packaging PR
"babel-register": "^6.9.0", | ||
"babel-eslint": "^10.0.0", | ||
"babel-jest": "^24.9.0", | ||
"babel-loader": "^8.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.
babel-loader
needs packaging PR.
(it is in the scope of webpack
, not babel
, as it's a webpack plugin)
Updates about packaging: @evgeni @ekohl @ehelms @tbrisker The last effort migrating to Therefore I created the To merge this PR, we need:
I didn't want to do all those changes by myself because I am not that familiar with the packaging and I guess they should all be done in 1 PR. Can I get some help here from the packaging team? |
This sounds sensible to me, but I'd like another ack from @ehelms or @ekohl. |
I can only agree with what @evgeni said. |
Include an upgrade for jest so test works with babel v7
1062f27
to
86d0a2f
Compare
Started builder packaging in theforeman/foreman-packaging#4413 |
babel-loader: theforeman/foreman-packaging#4416 |
so after building vendor 3.3.0, builder 3.3.0 and babel-loader 8.0.6, I get the following when trying to build foreman:
|
actually adding
|
- Consume prod babel from @theforeman/builder/babel - Consume dev babel from @theforeman/env/babel
It should work now :) |
So I tried with bec5ad8 (that was the version that was using 3.3.1) and it seemed to be fine. I needed to build babel-loader, @babel/core and obviously vendor and builder. 👍 I tried clicking around in the UI and saw no obvious errors, also nothing in the Console log. |
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.
packaging: ACK
Thanks @evgeni 👍 The Travis errors are unrelated: https://projects.theforeman.org/issues/28391 |
@sharvit makes sense, cool. can someone please ACK this from the JS/UX perspective please? |
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.
Thanks @sharvit, tested LGTM 👍
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.
Storybook is broken after the upgrade with this error:
ERROR in ./.storybook/config.js
Module build failed: Error: [BABEL] /home/afeferku/git/foreman/.storybook/config.js: Cannot find module
'@theforeman/vendor-core' (While processing:
"/home/afeferku/git/foreman/node_modules/@theforeman/env/babel/index.js")
EDIT: I was on an a previous version, after rebuilding it works well
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.
foreman and storybook work well 👍
tested in develop and production
Thanks @sharvit !
Thanks @amirfefer @LaViro @evgeni @xprazak2 @adamruzicka 👍 |
The babel configuration moved to
@theforeman/env
so it can be shared with core and plugins.