Mercurial > code > home > repos > streamed-graph
changeset 137:a8939c717015
still trying to get build right, but there are other update bugs too
author | drewp@bigasterisk.com |
---|---|
date | Sat, 06 May 2023 15:34:40 -0700 |
parents | d00036808948 |
children | ea0b4e46de2b |
files | package.json pnpm-lock.yaml src/SourceGraph.ts vite.config.ts |
diffstat | 4 files changed, 36 insertions(+), 7 deletions(-) [+] |
line wrap: on
line diff
--- a/package.json Sat May 06 14:20:33 2023 -0700 +++ b/package.json Sat May 06 15:34:40 2023 -0700 @@ -30,6 +30,7 @@ "sub-events": "^1.9.0" }, "devDependencies": { + "@rollup/plugin-alias": "^5.0.0", "@rollup/plugin-commonjs": "^24.1.0", "@rollup/plugin-node-resolve": "^15.0.2", "@rollup/plugin-terser": "^0.4.1",
--- a/pnpm-lock.yaml Sat May 06 14:20:33 2023 -0700 +++ b/pnpm-lock.yaml Sat May 06 15:34:40 2023 -0700 @@ -1,6 +1,7 @@ lockfileVersion: 5.4 specifiers: + '@rollup/plugin-alias': ^5.0.0 '@rollup/plugin-commonjs': ^24.1.0 '@rollup/plugin-node-resolve': ^15.0.2 '@rollup/plugin-terser': ^0.4.1 @@ -39,6 +40,7 @@ sub-events: 1.9.0 devDependencies: + '@rollup/plugin-alias': 5.0.0_rollup@3.21.5 '@rollup/plugin-commonjs': 24.1.0_rollup@3.21.5 '@rollup/plugin-node-resolve': 15.0.2_rollup@3.21.5 '@rollup/plugin-terser': 0.4.1_rollup@3.21.5 @@ -1135,6 +1137,19 @@ '@types/node': 20.1.0 dev: false + /@rollup/plugin-alias/5.0.0_rollup@3.21.5: + resolution: {integrity: sha512-l9hY5chSCjuFRPsnRm16twWBiSApl2uYFLsepQYwtBuAxNMQ/1dJqADld40P0Jkqm65GRTLy/AC6hnpVebtLsA==} + engines: {node: '>=14.0.0'} + peerDependencies: + rollup: ^1.20.0||^2.0.0||^3.0.0 + peerDependenciesMeta: + rollup: + optional: true + dependencies: + rollup: 3.21.5 + slash: 4.0.0 + dev: true + /@rollup/plugin-commonjs/24.1.0_rollup@3.21.5: resolution: {integrity: sha512-eSL45hjhCWI0jCCXcNtLVqM5N1JlBGvlFfY0m6oOYnLCJ6N0qEXoZql4sY2MOUArzhH4SA/qBpTxvvZp2Sc+DQ==} engines: {node: '>=14.0.0'} @@ -3434,6 +3449,11 @@ engines: {node: '>=8'} dev: true + /slash/4.0.0: + resolution: {integrity: sha512-3dOsAHXXUkQTpOYcoAxLIorMTp4gIQr5IW3iVb7A7lFIp0VHhnynm9izx6TssdrIcVIESAlVjtnO2K8bg+Coew==} + engines: {node: '>=12'} + dev: true + /smob/0.0.6: resolution: {integrity: sha512-V21+XeNni+tTyiST1MHsa84AQhT1aFZipzPpOFAVB8DkHzwJyjjAmt9bgwnuZiZWnIbMo2duE29wybxv/7HWUw==} dev: true
--- a/src/SourceGraph.ts Sat May 06 14:20:33 2023 -0700 +++ b/src/SourceGraph.ts Sat May 06 15:34:40 2023 -0700 @@ -40,6 +40,8 @@ // maybe the event messages should be 'add' and 'del', // for less parsing and clearer order of ops. ev.addEventListener("patch", async (ev) => { + // this is reentrant- ok? + const patchMsg = JSON.parse((ev as any).data); const p = new Patch(); @@ -53,6 +55,7 @@ p.applyToStore(this.store); console.log("patchlife0: eventsream store changed"); + // firing before there are listeners this.sourceGraphChanged.emit(p); if (firstPatch) { firstPatch = false;
--- a/vite.config.ts Sat May 06 14:20:33 2023 -0700 +++ b/vite.config.ts Sat May 06 15:34:40 2023 -0700 @@ -3,6 +3,7 @@ import rollupResolve from "@rollup/plugin-node-resolve"; import rollupCommonjs from "@rollup/plugin-commonjs"; +import rollupAlias from "@rollup/plugin-alias"; const config: UserConfigExport = { server: { host: "0.0.0.0", @@ -25,8 +26,9 @@ rollupResolve({ browser: true, preferBuiltins: false, + }), - rollupCommonjs(), + // rollupCommonjs(), // terser({ // mangle: false, // compress: false, @@ -34,16 +36,19 @@ // semicolons: false, // }, // }), + // rollupAlias({ + // entries: [{ find: "promises", replacement: "__my_promises__" }], + // }), ], }, minify: false, }, - resolve: { - alias: [{ find: "rdf-canonize-native", replacement: "" }], - }, - define: { - global: {}, - }, + // resolve: { + // alias: [{ find: "rdf-canonize-native", replacement: "" }], + // }, + // define: { + // global: {}, + // }, }; export default defineConfig(({ command, mode }) => {