mirror of
https://github.com/mdgriffith/elm-optimize-level-2.git
synced 2024-11-29 12:46:32 +03:00
Allow replacing a function/def with a whole bunch of code.
This commit is contained in:
parent
1e1c7e8eff
commit
a3b90e9b12
@ -3,7 +3,7 @@ import ts from 'typescript';
|
||||
|
||||
export const ast = (sourceText: string): ts.Node => {
|
||||
const source = ts.createSourceFile('bla', sourceText, ts.ScriptTarget.ES2018);
|
||||
return source.statements[0];
|
||||
return source.statements;
|
||||
};
|
||||
|
||||
export function create(name: string, body: ts.Node): ts.Node {
|
||||
|
Loading…
Reference in New Issue
Block a user