@polylith/builder 0.0.9 → 0.0.14
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.
- package/App.js +12 -2
- package/package.json +7 -2
package/App.js
CHANGED
|
@@ -1,9 +1,13 @@
|
|
|
1
|
+
import path from 'path';
|
|
2
|
+
|
|
1
3
|
import * as rollup from 'rollup';
|
|
2
4
|
import * as resolve from '@rollup/plugin-node-resolve';
|
|
3
5
|
import commonjs from '@rollup/plugin-commonjs';
|
|
6
|
+
import jsx from 'rollup-plugin-jsx';
|
|
7
|
+
import html from "rollup-plugin-html";
|
|
4
8
|
import loadables from './plugin-loadables.js';
|
|
5
9
|
import mainHTML from './plugin-main-html.js';
|
|
6
|
-
import
|
|
10
|
+
import styles from "rollup-plugin-styles";
|
|
7
11
|
|
|
8
12
|
export class App {
|
|
9
13
|
/*
|
|
@@ -100,8 +104,13 @@ export class App {
|
|
|
100
104
|
input: input,
|
|
101
105
|
plugins: [
|
|
102
106
|
resolve.nodeResolve(),
|
|
107
|
+
jsx( {factory: 'React.createElement'} ),
|
|
103
108
|
commonjs(),
|
|
104
109
|
loadables(this.loadables),
|
|
110
|
+
html({
|
|
111
|
+
include: path.join(this.basePath, "**/*.html"),
|
|
112
|
+
}),
|
|
113
|
+
styles(),
|
|
105
114
|
mainHTML({
|
|
106
115
|
template: this.htmlTemplate.template,
|
|
107
116
|
target: this.htmlTemplate.target,
|
|
@@ -114,7 +123,8 @@ export class App {
|
|
|
114
123
|
sourcemap: true,
|
|
115
124
|
dir : this.destination,
|
|
116
125
|
format: 'es',
|
|
117
|
-
}
|
|
126
|
+
},
|
|
127
|
+
assetFileNames: "[name]-[hash][extname]",
|
|
118
128
|
}
|
|
119
129
|
};
|
|
120
130
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@polylith/builder",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.14",
|
|
4
4
|
"description": "The polylith builder",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"type": "module",
|
|
@@ -12,8 +12,13 @@
|
|
|
12
12
|
"dependencies": {
|
|
13
13
|
"@rollup/plugin-commonjs": "^21.0.0",
|
|
14
14
|
"@rollup/plugin-node-resolve": "^13.0.5",
|
|
15
|
+
"rollup-plugin-jsx": "^1.0.3",
|
|
15
16
|
"escape-string-regexp": "^5.0.0",
|
|
16
17
|
"fs-extra": "^10.0.0",
|
|
17
|
-
"rollup": "^2.58.0"
|
|
18
|
+
"rollup": "^2.58.0",
|
|
19
|
+
"rollup-plugin-html": "^0.2.1",
|
|
20
|
+
"less": "^4.1.2",
|
|
21
|
+
"rollup-plugin-styles": "^3.14.1",
|
|
22
|
+
"sass": "^1.43.4"
|
|
18
23
|
}
|
|
19
24
|
}
|