@procore/core-scripts 9.6.3-beta.10 → 9.7.0-dart-sass

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (50) hide show
  1. package/README.md +1 -1
  2. package/dist/Generator.js +1 -1
  3. package/dist/Generator.js.map +1 -1
  4. package/dist/commands/app/build.js +5 -11
  5. package/dist/commands/app/build.js.map +1 -1
  6. package/dist/commands/app/start.js +7 -12
  7. package/dist/commands/app/start.js.map +1 -1
  8. package/dist/commands/e2e/gen.js.map +1 -1
  9. package/dist/commands/lib/build.js +2 -2
  10. package/dist/commands/lib/build.js.map +1 -1
  11. package/dist/commands/lib/start.js +1 -1
  12. package/dist/commands/lib/start.js.map +1 -1
  13. package/dist/commands/lint/stylelint.js.map +1 -1
  14. package/dist/commands/test.js +1 -2
  15. package/dist/commands/test.js.map +1 -1
  16. package/dist/index.js +0 -1
  17. package/dist/index.js.map +1 -1
  18. package/dist/jest/config.js +1 -2
  19. package/dist/jest/config.js.map +1 -1
  20. package/dist/paths.js +1 -2
  21. package/dist/paths.js.map +1 -1
  22. package/dist/procoreDevUtils/webpackHotDevClient.js +1 -2
  23. package/dist/procoreDevUtils/webpackHotDevClient.js.map +1 -1
  24. package/dist/webpack/app/devServerConfig.js +0 -3
  25. package/dist/webpack/app/devServerConfig.js.map +1 -1
  26. package/dist/webpack/app/index.js +5 -1
  27. package/dist/webpack/app/index.js.map +1 -1
  28. package/dist/webpack/app/setupWebpack.js +41 -115
  29. package/dist/webpack/app/setupWebpack.js.map +1 -1
  30. package/dist/webpack/library/index.js.map +1 -1
  31. package/dist/webpack/library/setupWebpack.js +0 -34
  32. package/dist/webpack/library/setupWebpack.js.map +1 -1
  33. package/docs/commands/app.md +4 -5
  34. package/docs/commands/e2e.md +2 -2
  35. package/docs/commands/info.md +1 -1
  36. package/docs/commands/lib.md +3 -3
  37. package/docs/commands/lint.md +2 -2
  38. package/docs/commands/rm.md +1 -1
  39. package/docs/commands/test.md +1 -1
  40. package/oclif.manifest.json +1 -1
  41. package/package.json +60 -87
  42. package/public/index.html +0 -1
  43. package/CHANGELOG.md +0 -765
  44. package/dist/procoreDevUtils/WebpackDevServerUtils.js +0 -415
  45. package/dist/procoreDevUtils/WebpackDevServerUtils.js.map +0 -1
  46. package/dist/procoreDevUtils/formatWebpackMessages.js +0 -96
  47. package/dist/procoreDevUtils/formatWebpackMessages.js.map +0 -1
  48. package/dist/webpack/app/pluginDecorators/moduleFederationDecorator.js +0 -64
  49. package/dist/webpack/app/pluginDecorators/moduleFederationDecorator.js.map +0 -1
  50. package/docs/upgrading_to_v10.md +0 -95
@@ -1,95 +0,0 @@
1
- # Upgrading to `@procore/core-scripts` v10
2
-
3
- ## Why upgrade
4
-
5
- In this latest version of core-scripts, we are not bringing any new CLI functionality. It is primarily an upgrade to webpack 5 under the hood.
6
-
7
- This brings the exciting new capability of [module federation](https://indepth.dev/posts/1173/webpack-5-module-federation-a-game-changer-in-javascript-architecture), which is webpack's solution to micro frontends.
8
-
9
- If you would like to read more about the planned micro frontend architecture at Procore, please visit [this comprehensive overview](https://procoretech.atlassian.net/wiki/spaces/AA/pages/1613758671/Micro+Frontends).
10
-
11
- ## Upgrade steps
12
-
13
- - Update your `package.json` to use the latest version of `@procore/core-scripts` and run `yarn install`
14
- - Try to run `yarn core-scripts app:start` and `yarn core-scripts app:build`
15
-
16
- ## Enabling Module Federation for your app
17
-
18
- The primary reason to upgrade to core-scripts v10 is to enable module federation. Ths is pretty easy to do in an application. You will need to edit your `procore.config.js`. Let's dissect the following module configuration a bit:
19
-
20
- ```js
21
- module.exports = () => {
22
- return {
23
- app: {
24
- moduleFederation: {
25
- // This is your unique application id. Replace "myapp" with a unique string.
26
- // The recommendation to ensure uniqueness is to use a camelcased version
27
- // of your app's repository name.
28
- id: 'myapp',
29
-
30
- // You can expose (share) multiple components between micro frontends.
31
- // For now, we are simply exposing our CustomElement component mount point,
32
- // which calls ReactDOM.render to render out the application into a custom element.
33
- //
34
- // Rendering into a custom element is important because it provides encapsulation from
35
- // other micro frontends.
36
-
37
- // The keys should be PascalCased, and the values should point straight to component src files
38
- exposes: {
39
- MyApp: 'src/CustomElement.js',
40
- },
41
-
42
- // The dependencies listed here will be "shared" by micro frontends. This
43
- // means that if your application is loaded into the host, and the host
44
- // already contains dependencies that you are intending to use, it will
45
- // re-use the host's depedencies first
46
- //
47
- // Keep in mind that pinning dependencies will likely result in the
48
- // dependencies not being shared.
49
- //
50
- // But also keep in mind that not pinning dependencies can potentially
51
- // result in runtime errors, which must be handled accordingly.
52
- //
53
- // We should strive to enable dependabot or some type of automated
54
- // dependency updater on application repositories so that that all of
55
- // our applications are using similar versions of shared dependencies.
56
- shared: {
57
- react: '16.13.1',
58
- 'react-dom': '16.13.1',
59
- 'react-router-dom': '^5.2.0',
60
- },
61
- },
62
- },
63
-
64
- // ... other config
65
- }
66
- }
67
- ```
68
-
69
- If you would like to know more about module federation in general, please visit https://webpack.js.org/concepts/module-federation/ for reference.
70
-
71
- ## Things to account for
72
-
73
- The upgrade process should be relatively straightforward, but this is assuming the client at hand does not have significant modifications to the webpack config via `procore.config.js`.
74
-
75
- If your client has many webpack modifications, you may need to account for it during the upgrade process. In particular you may want to note the following:
76
-
77
- ### Custom loaders or plugins (or any other dependencies)
78
-
79
- If the client has added any custom loaders or plugins to the webpack config, you will want to ensure that these plugins are compatible with webpack 5.
80
-
81
- ### Overriding style-loader or css-loader options
82
-
83
- In the latest version of style-loader and css-loader, the default options for importing styles have changed. Of particular note is the [esModule](https://webpack.js.org/loaders/css-loader/#esmodule) option which now has the default set to `true`.
84
-
85
- We have accounted for this in the base configuration that core-scripts uses, but if a client has happened to override configuration for either of these loaders it may need to be accounted for.
86
-
87
- If you are importing scss styles and the css module names appear wonky this is most likely to be the culprit.
88
-
89
- ### Read the general webpack 4 to 5 upgrade guidelines
90
-
91
- https://webpack.js.org/migrate/5/
92
-
93
- ## Reach Out
94
-
95
- If you are having difficulties upgrading to webpack 5 and need help please reach out to the Frontend Foundations team.