26 Commits

Author SHA1 Message Date
Jason Jean
76dfc62412
feat(web): replace usages of @nrwl with @nx (#16376) 2023-04-19 10:59:41 -04:00
Jack Hsu
d8f9f32e7a
fix(react): update types for "@nrwl/react/plugins/webpack" for projec… (#15235) 2023-02-24 18:43:29 +02:00
Jack Hsu
454fba49b2
feat(webpack): generate React and Web apps with webpack.config.js file (#14285) 2023-01-12 10:06:25 -05:00
Jack Hsu
6feb56e014
feat(webpack): remove support for legacy browsers (#14190) (#14257) 2023-01-11 10:13:35 +02:00
Nikita Glazov
37dc336a0a
fix(nx/react): wrong svg import processing (#12477) 2022-12-19 15:45:33 -05:00
David (ダビッド )
34fdbc0de2
fix(react): fix webpack node api config error serving a react app (#11580)
Webpack compiles a react app and the main.js file created contains __dirname variable. This crash
the application when it is served. The webpack node api config has been enabled.

ISSUES CLOSED: #11571
2022-08-17 13:55:32 -04:00
Nicholas Cunningham
12f0f195d2
feat(react): add support for MFEs (#9413)
* feat(react): Add MFE  Generator for Host and Remote Apps
Host generator will be able use the mfe-remote generator when remotes are passed into the CLI for the mfe-host command

* docs(react): React Documentation Update

Co-authored-by: Nicholas Cunningham <nico@Nicholass-MacBook-Pro.local>
Co-authored-by: Nicholas Cunningham <ndcunningham>
2022-04-04 15:44:18 -04:00
Jack Hsu
120e987580
fix(react): fix issue with postcss and images in webpack config (#8802)
Fixes #8300
2022-02-01 11:43:01 -05:00
William Ghelfi
b577646589
feat(storybook): enable SVGR support for MDX stories (#7553)
* chore(core): nx plugin submission nx-plugin-unused-deps

* feat(storybook): enable SVGR support for MDX stories
2022-01-27 08:49:34 -05:00
Jack Hsu
9c1ae3a1b0
chore(web): clean up webpack setup (#7411) 2021-10-19 09:07:33 -06:00
Leosvel Pérez Espinosa
324129b88d
fix(react): fix react webpack plugin check for babel-loader (#7382) 2021-10-15 12:53:01 -04:00
Jack Hsu
724b0c0e3c
feat(core): upgrade to webpack 5 (#7283)
* feat(core): upgrade to webpack 5

* chore(core): update webpack 5 docs
2021-10-13 00:34:28 -04:00
Jack Hsu
70c0921180
feat(react): add fast refresh support for webpack 5 (#6529) 2021-07-29 18:16:26 +00:00
Jack Hsu
369da3ee78
feat(web): add support for webpack 5 (#5892) 2021-06-29 08:41:01 -04:00
Emily Xiong
b8584a6f18
feat(react): add react fast refresh to webpack (#5612) 2021-05-18 15:47:18 -04:00
William Ghelfi
742ea79d53
Fix svgr/webpack conf (#4327)
* fix(misc): avoid issues with refs in SVGs

The previous "import friendly" syntax was actually disabling refs in SVGs parsed by svgr.

I found 3 possible solutions:
1. Removing "![path]"
2. Separating "+ref![path]" with another comma: "+ref,![path]"
3. Rewriting the loader entry in the style of the other loader entries

I chose the last one for added clarity within the file.

* fix(core): fix compilation errors
2021-01-15 09:09:55 -05:00
Spencer Elliott
5b6df632cb
fix(core): resolve webpack loaders with require.resolve() (#3436)
* fix(core): resolve webpack loaders with `require.resolve()`

With strict package managers such as pnpm or Yarn PnP, transitive
dependencies are *not* hoisted to the root node_modules folder. This
means that a webpack config defined within a package like
'@nrwl/cypress' cannot resolve loaders like 'ts-loader', unless
'ts-loader' is declared in the workspace's own package.json.

This is a problem because the workspace might define a different version
of 'ts-loader', incompatible with the version declared by
'@nrwl/cypress/package.json'. The workspace should not need to declare
a dependency on 'ts-loader' anyway.

See also:
* https://github.com/pnpm/pnpm/issues/801
* https://github.com/webpack/webpack/issues/5087

* fix(core): resolve absolute 'raw-loader' path

When replacing the 'raw-loader' rule in the `getStylesPartial` function,
check for the absolute path of 'raw-loader' rather than just the name.
2020-08-08 17:53:00 -04:00
Jack Hsu
ed8bd2bbe8
Revert "fix(core): resolve webpack loaders with require.resolve() (#3341)" (#3371)
This reverts commit d74ab4e9d6eae6d83c3bb76072b45f7a4c7a6305.
2020-07-20 16:24:47 -04:00
Jack Hsu
83865747e9
fix(react): move url-loader to the react package.json (#3356) 2020-07-17 10:41:16 -04:00
Spencer Elliott
d74ab4e9d6
fix(core): resolve webpack loaders with require.resolve() (#3341)
With strict package managers such as pnpm or Yarn PnP, transitive
dependencies are *not* hoisted to the root node_modules folder. This
means that a webpack config defined within a package like
'@nrwl/cypress' cannot resolve loaders like 'ts-loader', unless
'ts-loader' is declared in the workspace's own package.json.

This is a problem because the workspace might define a different version
of 'ts-loader', incompatible with the version declared by
'@nrwl/cypress/package.json'. The workspace should not need to declare
a dependency on 'ts-loader' anyway.

See also:
* https://github.com/pnpm/pnpm/issues/801
* https://github.com/webpack/webpack/issues/5087
2020-07-15 13:55:38 -04:00
Jack Hsu
d593153a33
feat(react): refactored babel support so options are more easily customized (#3089)
This reverts commit 7679df22f5b90d085b5f32f2135d828036ee5aa7.
2020-05-29 02:09:47 -04:00
Victor Savkin
7679df22f5 Revert "feat(react): refactored babel support so options are more easily customized (#3058)"
This reverts commit 0e036272cbe156fe9750a2f2bc6498a08cf7f457.
2020-05-28 13:11:56 -04:00
Jack Hsu
0e036272cb
feat(react): refactored babel support so options are more easily customized (#3058) 2020-05-26 09:16:36 -04:00
Jason Jean
e06822da7e
chore(repo): update prettier to v2 (#2934)
this is just for the repo, and not the workspace

Co-authored-by: Rares Matei <matei.rar@gmail.com>
2020-04-29 01:09:37 -04:00
Jack Hsu
20885513ae
fix(react): add fallback for SVG imports coming from non-TS/JS modules (#2351) 2020-01-21 10:06:30 -05:00
Jack Hsu
df7ff8cbae
feat(react): add better support for file and image imports (#2245) 2019-12-30 13:36:44 -05:00