@riboseinc/anafero-cli 0.0.31 → 0.0.33
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/CLI.tsx +12 -1
- package/bootstrap.js +124129 -124126
- package/bootstrap.js.map +1 -1
- package/build-generator.mts +4 -22
- package/build-site.mjs +8313 -8253
- package/package.json +2 -1
- package/riboseinc-anafero-cli-0.0.33.tgz +0 -0
- package/riboseinc-anafero-cli-0.0.31.tgz +0 -0
package/build-generator.mts
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
9
|
import { resolve, isAbsolute, join } from 'node:path';
|
|
10
|
-
import { readFile
|
|
10
|
+
import { readFile } from 'node:fs/promises';
|
|
11
11
|
|
|
12
12
|
import { Logger, Effect } from 'effect';
|
|
13
13
|
import { NodeContext, NodeRuntime } from '@effect/platform-node';
|
|
@@ -66,8 +66,7 @@ Effect.
|
|
|
66
66
|
|
|
67
67
|
async function buildBootstrapScript(opts: ReportingOptions) {
|
|
68
68
|
const { logLevel } = opts;
|
|
69
|
-
|
|
70
|
-
const result = await esbuild({
|
|
69
|
+
return await esbuild({
|
|
71
70
|
entryPoints: [
|
|
72
71
|
'./bootstrap.tsx',
|
|
73
72
|
//join(PACKAGE_ROOT, 'site', 'index.tsx'),
|
|
@@ -75,14 +74,14 @@ async function buildBootstrapScript(opts: ReportingOptions) {
|
|
|
75
74
|
absWorkingDir: join(PACKAGE_ROOT, '..', 'firelight-gui'),
|
|
76
75
|
entryNames: '[dir]/[name]',
|
|
77
76
|
assetNames: '[dir]/[name]',
|
|
78
|
-
format: '
|
|
77
|
+
format: 'iife',
|
|
79
78
|
target: ['esnext'],
|
|
80
79
|
bundle: true,
|
|
81
80
|
minify: false,
|
|
82
81
|
treeShaking: true,
|
|
83
82
|
sourcemap: true,
|
|
84
83
|
platform: 'browser',
|
|
85
|
-
outfile,
|
|
84
|
+
outfile: join(PACKAGE_ROOT, 'bootstrap.js'),
|
|
86
85
|
//outdir: 'layout',
|
|
87
86
|
write: true,
|
|
88
87
|
loader: {
|
|
@@ -93,23 +92,6 @@ async function buildBootstrapScript(opts: ReportingOptions) {
|
|
|
93
92
|
},
|
|
94
93
|
logLevel,
|
|
95
94
|
});
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
// This unbreaks react-aria’s virtualizer ScrollView
|
|
99
|
-
// interfering with ProseMirror
|
|
100
|
-
//
|
|
101
|
-
// Ideally, this could be an esbuild plugin.
|
|
102
|
-
// Even more ideally, a proper package manager patch
|
|
103
|
-
// (yarn patch didn’t work for me).
|
|
104
|
-
console.debug("Patching ProseMirror");
|
|
105
|
-
let contents = await readFile(outfile, 'utf8');
|
|
106
|
-
contents = contents.replace(
|
|
107
|
-
'if (!runCustomHandler(view, event)',
|
|
108
|
-
'if (event && !runCustomHandler(view, event)',
|
|
109
|
-
);
|
|
110
|
-
await writeFile(outfile, contents);
|
|
111
|
-
|
|
112
|
-
return result;
|
|
113
95
|
}
|
|
114
96
|
|
|
115
97
|
/**
|