Skip to content

Commit

Permalink
Build adjustments
Browse files Browse the repository at this point in the history
  • Loading branch information
yojeek committed Jan 17, 2024
1 parent c38ef5a commit 5206d9d
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 14 deletions.
1 change: 1 addition & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
dist
node_modules
webpack.config.js
**/vite.config.ts
3 changes: 2 additions & 1 deletion packages/core/tsconfig.build.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
{
"extends": "./tsconfig.json",
"compilerOptions": {
"outDir": "dist"
"outDir": "dist",
"sourceMap": true
},
"include": ["src/**/*.ts"]
}
3 changes: 2 additions & 1 deletion packages/engine/tsconfig.build.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
{
"extends": "./tsconfig.json",
"compilerOptions": {
"outDir": "dist"
"outDir": "dist",
"sourceMap": true
},
"include": ["src/**/*.ts"]
}
33 changes: 21 additions & 12 deletions packages/renderer-vue/playground/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,6 @@ engine.events.afterRun.subscribe(token, (r) => {
engine.pause();
applyResult(r, editor);
engine.resume();
console.log(r);
});
engine.hooks.gatherCalculationData.subscribe(token, () => "def");
engine.start();
Expand All @@ -80,28 +79,36 @@ editor.registerNodeType(DynamicNode);
editor.registerNodeType(UpdateTestNode);
editor.registerNodeType(ReactiveOutputTestNode);
editor.graph.addNode(new TestNode());
editor.graph.addNode(new TestNode());
editor.graph.addNode(new TestNode());
editor.graph.addNode(new OutputNode());
editor.graph.addNode(new BuilderTestNode());
editor.graph.addNode(new AdvancedNode());
const calculate = async () => {
console.log(await engine.runOnce("def"));
};
const save = () => {
console.log(JSON.stringify(editor.save()));
let state = editor.save();
window.localStorage.setItem("baklava", JSON.stringify(state));
console.log('Saved state to localStorage');
};
const load = () => {
const s = prompt();
if (s) {
editor.load(JSON.parse(s));
let state;
try {
state = JSON.parse(window.localStorage.getItem("baklava")!);
if (state) {
editor.load(state);
return;
}
console.log('Loaded state from localStorage')
} catch (e) {
console.error(e);
return;
}
};
load();
const saveAndLoad = () => {
editor.load(editor.save());
};
Expand All @@ -117,6 +124,8 @@ const setSelectItems = () => {
];
}
}
state && editor.load(state);
};
const changeGridSize = () => {
Expand Down
1 change: 1 addition & 0 deletions packages/renderer-vue/vite.config.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
/// <reference types="@types/node" />
// @ts-nocheck

import * as path from "path";
import { defineConfig } from "vite";
Expand Down

0 comments on commit 5206d9d

Please sign in to comment.