Dead code. cleaning up parse. allowing trailing commas. starting to work on the 'os' palette
This commit is contained in:
parent
a30d2217b8
commit
2d687b5d38
5 changed files with 77 additions and 112 deletions
|
|
@ -13,9 +13,7 @@ import stdlibCode from './stdlib.cg?raw';
|
|||
import designTokensCode from './design-tokens.cg?raw';
|
||||
import uiComponentsCode from './ui-components.cg?raw';
|
||||
|
||||
import textInputCode from './textinput-test.cg?raw';
|
||||
// import testCode from './test.cg?raw';
|
||||
// import counterApp from './counter.cg?raw';
|
||||
import osCode from './os.cg?raw';
|
||||
|
||||
const canvas = document.createElement('canvas') as HTMLCanvasElement;
|
||||
document.body.appendChild(canvas);
|
||||
|
|
@ -28,7 +26,7 @@ if (clearButton) {
|
|||
const cgCode = stdlibCode + '\n' +
|
||||
designTokensCode + '\n' +
|
||||
uiComponentsCode + '\n' +
|
||||
textInputCode + '\n'
|
||||
osCode + '\n'
|
||||
|
||||
try {
|
||||
const tokens = tokenize(cgCode);
|
||||
|
|
@ -41,7 +39,8 @@ try {
|
|||
const persisted = loadStore();
|
||||
|
||||
for (const def of definitions) {
|
||||
const body = persisted?.[def.name]?.body ?? def.body;
|
||||
// const body = persisted?.[def.name]?.body ?? def.body;
|
||||
const body = def.body;
|
||||
|
||||
const deps = startTracking(def.name);
|
||||
const value = evaluate(body, env, cgCode);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue