Type constructors
This commit is contained in:
parent
635f12490d
commit
668ee3e4d8
4 changed files with 50 additions and 17 deletions
|
|
@ -23,13 +23,13 @@ store.viewport = { width: window.innerWidth, height: window.innerHeight };
|
|||
try {
|
||||
const tokens = tokenize(cgCode);
|
||||
const parser = new Parser(tokens, cgCode);
|
||||
const { definitions: defs } = parser.parse();
|
||||
const { definitions: defs, typeDefinitions: typeDefs } = parser.parse();
|
||||
loadDefinitions();
|
||||
|
||||
// TODO remove once we're booting from store, files are backup
|
||||
if (!store.paletteHistory) store.paletteHistory = [];
|
||||
|
||||
compileAndRun(defs);
|
||||
compileAndRun(defs, typeDefs);
|
||||
saveDefinitions();
|
||||
|
||||
runAppCompiled(canvas, store);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue