@genesislcap/webpack-builder 14.62.2-alpha-39ca39f.0 → 14.63.0

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.
@@ -1 +1 @@
1
- {"version":3,"file":"plugins.d.ts","sourceRoot":"","sources":["../../src/config/plugins.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AAK3D,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAqB7C,eAAO,MAAM,OAAO,QAAS,YAAY,KAAG,aAAa,CAAC,SAAS,CAwElE,CAAC"}
1
+ {"version":3,"file":"plugins.d.ts","sourceRoot":"","sources":["../../src/config/plugins.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AAK3D,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAiB7C,eAAO,MAAM,OAAO,QAAS,YAAY,KAAG,aAAa,CAAC,SAAS,CAkElE,CAAC"}
@@ -15,17 +15,12 @@ const webpackbar_1 = tslib_1.__importDefault(require("webpackbar"));
15
15
  const workbox_webpack_plugin_1 = require("workbox-webpack-plugin");
16
16
  const federation_1 = require("./federation");
17
17
  const getTemplate = (cwd) => {
18
- let selectedTemplate = (0, node_path_1.resolve)(__dirname, '../public/index.html');
19
18
  const templateApp = (0, node_path_1.resolve)(cwd, 'index.html');
20
- const templateAppPublic = (0, node_path_1.resolve)(cwd, 'public/index.ejs');
21
- if ((0, node_fs_1.existsSync)(templateApp)) {
22
- selectedTemplate = templateApp;
23
- }
24
- else if ((0, node_fs_1.existsSync)(templateAppPublic)) {
25
- selectedTemplate = templateAppPublic;
26
- }
27
- console.log(`Using index template: ${selectedTemplate}`);
28
- return `!!handlebars-loader!${selectedTemplate}`;
19
+ const template = (0, node_fs_1.existsSync)(templateApp)
20
+ ? templateApp
21
+ : (0, node_path_1.resolve)(__dirname, '../public/index.html');
22
+ console.log(`Using index template: ${template}`);
23
+ return `!!handlebars-loader!${template}`;
29
24
  };
30
25
  const plugins = (ctx) => {
31
26
  const { cli: { isAnalyze }, dirs: { cwd }, config: { serviceWorker, pwa, federation, app: { rootElement }, http, env, }, pkg, } = ctx;
@@ -33,17 +28,12 @@ const plugins = (ctx) => {
33
28
  const moduleFederationOptions = (0, federation_1.resolveFederationOptions)(federation, pkg);
34
29
  const define = (0, build_kit_1.resolveDefineConfig)(env, http);
35
30
  const appPublic = (0, node_path_1.resolve)(cwd, 'public');
36
- console.log('--webpack builder -- resolving app public', appPublic);
37
- console.log('--webpack builder -- app public exists?', (0, node_fs_1.existsSync)(appPublic));
38
31
  return [
39
32
  (0, node_fs_1.existsSync)(appPublic) &&
40
33
  new copy_webpack_plugin_1.default({
41
34
  patterns: [
42
- // {
43
- // from: resolve(__dirname, '../../public'),
44
- // },
45
35
  {
46
- from: (0, node_path_1.resolve)(cwd, 'public'),
36
+ from: appPublic,
47
37
  },
48
38
  ],
49
39
  }),
@@ -1 +1 @@
1
- {"version":3,"file":"fileRules.d.ts","sourceRoot":"","sources":["../../../src/config/rules/fileRules.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;CAoBxB,CAAC"}
1
+ {"version":3,"file":"fileRules.d.ts","sourceRoot":"","sources":["../../../src/config/rules/fileRules.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;CAiBxB,CAAC"}
@@ -12,9 +12,6 @@ exports.appFileRules = {
12
12
  html: () => ({
13
13
  test: /\.html$/,
14
14
  use: [
15
- // {
16
- // loader: 'handlebars-loader',
17
- // },
18
15
  {
19
16
  loader: 'html-loader',
20
17
  },
@@ -19,8 +19,5 @@
19
19
  </head>
20
20
  <body>
21
21
  <{{htmlWebpackPlugin.options.customElementTagName}}></{{htmlWebpackPlugin.options.customElementTagName}}>
22
- {{#if insertEntryPoint}}
23
- <script type="module" src="/src/index.ts"></script>
24
- {{/if}}
25
22
  </body>
26
23
  </html>
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@genesislcap/webpack-builder",
3
3
  "description": "Webpack builder",
4
- "version": "14.62.2-alpha-39ca39f.0",
4
+ "version": "14.63.0",
5
5
  "license": "SEE LICENSE IN license.txt",
6
6
  "main": "dist/index.js",
7
7
  "types": "dist/index.d.ts",
@@ -12,7 +12,7 @@
12
12
  "dev": "tsc -b ./tsconfig.json -w"
13
13
  },
14
14
  "dependencies": {
15
- "@genesislcap/build-kit": "14.62.2-alpha-39ca39f.0",
15
+ "@genesislcap/build-kit": "14.63.0",
16
16
  "@module-federation/dashboard-plugin": "2.6.5",
17
17
  "@pixability-ui/federated-types": "^0.2.0",
18
18
  "camel-case": "^4.1.2",
@@ -54,5 +54,5 @@
54
54
  "publishConfig": {
55
55
  "access": "public"
56
56
  },
57
- "gitHead": "9faeaf6754a5eba4ef5f9f01452ec421d8846105"
57
+ "gitHead": "8f0b586dcf840766f1799edde09d97b4c8c483a1"
58
58
  }
package/public/index.html CHANGED
@@ -19,8 +19,5 @@
19
19
  </head>
20
20
  <body>
21
21
  <{{htmlWebpackPlugin.options.customElementTagName}}></{{htmlWebpackPlugin.options.customElementTagName}}>
22
- {{#if insertEntryPoint}}
23
- <script type="module" src="/src/index.ts"></script>
24
- {{/if}}
25
22
  </body>
26
23
  </html>
@@ -14,16 +14,12 @@ import { InjectManifest } from 'workbox-webpack-plugin';
14
14
  import { getFederationPlugins, federatedIndexExists, resolveFederationOptions } from './federation';
15
15
 
16
16
  const getTemplate = (cwd) => {
17
- let selectedTemplate = resolve(__dirname, '../public/index.html');
18
17
  const templateApp = resolve(cwd, 'index.html');
19
- const templateAppPublic = resolve(cwd, 'public/index.ejs');
20
- if (existsSync(templateApp)) {
21
- selectedTemplate = templateApp;
22
- } else if (existsSync(templateAppPublic)) {
23
- selectedTemplate = templateAppPublic;
24
- }
25
- console.log(`Using index template: ${selectedTemplate}`);
26
- return `!!handlebars-loader!${selectedTemplate}`;
18
+ const template = existsSync(templateApp)
19
+ ? templateApp
20
+ : resolve(__dirname, '../public/index.html');
21
+ console.log(`Using index template: ${template}`);
22
+ return `!!handlebars-loader!${template}`;
27
23
  };
28
24
 
29
25
  export const plugins = (ctx: BuildContext): Configuration['plugins'] => {
@@ -44,20 +40,14 @@ export const plugins = (ctx: BuildContext): Configuration['plugins'] => {
44
40
  const federatedIndexPresent = federatedIndexExists();
45
41
  const moduleFederationOptions = resolveFederationOptions(federation, pkg);
46
42
  const define = resolveDefineConfig(env, http);
47
-
48
43
  const appPublic = resolve(cwd, 'public');
49
- console.log('--webpack builder -- resolving app public', appPublic);
50
- console.log('--webpack builder -- app public exists?', existsSync(appPublic));
51
44
 
52
45
  return [
53
46
  existsSync(appPublic) &&
54
47
  new CopyPlugin({
55
48
  patterns: [
56
- // {
57
- // from: resolve(__dirname, '../../public'),
58
- // },
59
49
  {
60
- from: resolve(cwd, 'public'),
50
+ from: appPublic,
61
51
  },
62
52
  ],
63
53
  }),
@@ -10,9 +10,6 @@ export const appFileRules = {
10
10
  html: () => ({
11
11
  test: /\.html$/,
12
12
  use: [
13
- // {
14
- // loader: 'handlebars-loader',
15
- // },
16
13
  {
17
14
  loader: 'html-loader',
18
15
  },
Binary file
@@ -1,3 +0,0 @@
1
- {
2
- "rewrites": [ { "source": "/**", "destination": "/index.html" } ]
3
- }
Binary file
package/public/serve.json DELETED
@@ -1,3 +0,0 @@
1
- {
2
- "rewrites": [ { "source": "/**", "destination": "/index.html" } ]
3
- }