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

feat(plugin-webpack): Support non-js webpack configuration languages #2747

Closed
wants to merge 3 commits into from

Conversation

issacgerges
Copy link
Contributor

@issacgerges issacgerges commented Mar 1, 2022

  • I have read the contribution documentation for this project.
  • I agree to follow the code of conduct that this project follows, as appropriate.
  • The changes are appropriately documented (if applicable).
  • The changes have sufficient test coverage (if applicable).
  • The testsuite passes successfully on my local machine (if applicable).

Summarize your changes:

This change adds gulpjs/interpret and gulpjs/rechoir to add support similar to webpack's configuration languages. These changes heavily mirror what webpack itself does

Fixes #697

before

image

after installing ts-node and typescript

image

@issacgerges issacgerges force-pushed the issacgerges/non_js_webpack_config branch from 1a2b92f to ae748c1 Compare March 1, 2022 21:39
@codecov
Copy link

codecov bot commented Mar 1, 2022

Codecov Report

Merging #2747 (68c73cc) into main (e404bf1) will decrease coverage by 12.59%.
The diff coverage is 75.00%.

❗ Current head 68c73cc differs from pull request most recent head cad1f19. Consider uploading reports for the commit cad1f19 to get more accurate results

Impacted file tree graph

@@             Coverage Diff             @@
##             main    #2747       +/-   ##
===========================================
- Coverage   73.91%   61.31%   -12.60%     
===========================================
  Files          67       74        +7     
  Lines        2185     2306      +121     
  Branches      438      434        -4     
===========================================
- Hits         1615     1414      -201     
- Misses        356      700      +344     
+ Partials      214      192       -22     
Impacted Files Coverage Δ
packages/plugin/webpack/src/WebpackConfig.ts 94.73% <75.00%> (+0.11%) ⬆️
...ges/api/core/src/api/init-scripts/find-template.ts 23.80% <0.00%> (-71.43%) ⬇️
...es/api/core/src/api/init-scripts/init-directory.ts 31.25% <0.00%> (-62.50%) ⬇️
packages/api/core/src/api/init.ts 36.11% <0.00%> (-55.56%) ⬇️
packages/api/core/src/api/package.ts 22.22% <0.00%> (-53.34%) ⬇️
packages/api/core/src/util/rebuild.ts 21.05% <0.00%> (-47.37%) ⬇️
packages/api/core/src/api/import.ts 16.66% <0.00%> (-45.10%) ⬇️
packages/api/core/src/api/index.ts 45.45% <0.00%> (-43.44%) ⬇️
packages/api/core/src/api/init-scripts/init-npm.ts 61.90% <0.00%> (-38.10%) ⬇️
packages/api/core/src/util/electron-executable.ts 76.00% <0.00%> (-24.00%) ⬇️
... and 62 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update e404bf1...cad1f19. Read the comment docs.

if (isRechoirError(error)) {
const { message, failures } = error;
const logLines = [
`Unable to load webpack config '${config}'`,
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
`Unable to load webpack config '${config}'`,
`\nUnable to load webpack config '${config}'`,

Just so it isn't on the same line as the still painting ora

@issacgerges issacgerges force-pushed the issacgerges/non_js_webpack_config branch from ae748c1 to c22fb09 Compare March 2, 2022 00:35
@issacgerges issacgerges marked this pull request as draft October 26, 2022 20:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[6.x] Webpack: Support configs written in non-JavaScript
3 participants