@hubspot/ui-extensions-dev-server 0.6.0 → 0.6.1-next.9
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/lib/build.js
CHANGED
|
@@ -52,7 +52,7 @@ async function buildSingleExtension({
|
|
|
52
52
|
rollupOptions: {
|
|
53
53
|
...ROLLUP_OPTIONS,
|
|
54
54
|
plugins: [
|
|
55
|
-
manifestPlugin({ output, logger }),
|
|
55
|
+
manifestPlugin({ minify, output, logger }),
|
|
56
56
|
codeInjectionPlugin({ file }),
|
|
57
57
|
],
|
|
58
58
|
},
|
|
@@ -75,16 +75,12 @@ async function remoteBuild(
|
|
|
75
75
|
throw new Error(`${extensionErrorBaseMessage} ${fileInfo.ext}`);
|
|
76
76
|
}
|
|
77
77
|
|
|
78
|
-
const output = getUrlSafeFileName(entryPoint);
|
|
79
78
|
await buildSingleExtension({
|
|
80
79
|
file: entryPoint,
|
|
81
|
-
outputFileName: output,
|
|
82
80
|
outputDir,
|
|
83
|
-
plugins: {
|
|
84
|
-
rollup: [manifestPlugin({ minify: true, output, logger })],
|
|
85
|
-
},
|
|
86
81
|
minify: true,
|
|
87
82
|
root,
|
|
83
|
+
logger
|
|
88
84
|
});
|
|
89
85
|
}
|
|
90
86
|
|
|
@@ -1,16 +1,13 @@
|
|
|
1
1
|
const path = require('path');
|
|
2
2
|
|
|
3
|
-
function codeInjectionPlugin(
|
|
4
|
-
const { file, root = process.cwd() } = options;
|
|
3
|
+
function codeInjectionPlugin() {
|
|
5
4
|
return {
|
|
6
5
|
name: 'ui-extensions-code-injection-plugin',
|
|
7
6
|
enforce: 'post', // run after default rollup plugins
|
|
8
|
-
transform(code,
|
|
9
|
-
const
|
|
10
|
-
? file
|
|
11
|
-
: path.join(root, file);
|
|
7
|
+
transform(code, file) {
|
|
8
|
+
const { dir } = path.parse(file);
|
|
12
9
|
|
|
13
|
-
if (
|
|
10
|
+
if (dir.includes('node_modules')) {
|
|
14
11
|
return { code, map: null }; // Not the file we care about, return the same code
|
|
15
12
|
}
|
|
16
13
|
|
|
@@ -44,6 +44,13 @@ function devBuildPlugin(options = {}) {
|
|
|
44
44
|
process.env.NODE_ENV || 'development'
|
|
45
45
|
),
|
|
46
46
|
},
|
|
47
|
+
esbuild: {
|
|
48
|
+
tsconfigRaw: {
|
|
49
|
+
compilerOptions: {
|
|
50
|
+
preserveValueImports: true,
|
|
51
|
+
},
|
|
52
|
+
},
|
|
53
|
+
},
|
|
47
54
|
build: {
|
|
48
55
|
lib: {
|
|
49
56
|
entry: extensionConfig.data.module.file,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hubspot/ui-extensions-dev-server",
|
|
3
|
-
"version": "0.6.
|
|
3
|
+
"version": "0.6.1-next.9+85660802",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"scripts": {
|
|
@@ -67,5 +67,5 @@
|
|
|
67
67
|
"optional": true
|
|
68
68
|
}
|
|
69
69
|
},
|
|
70
|
-
"gitHead": "
|
|
70
|
+
"gitHead": "85660802fede329b3da761adabb509cb9f376d3e"
|
|
71
71
|
}
|