Abstract Syntax Tree for SWF
npm install swf-tree
alt="Open Flash logo" title="Open Flash" align="right" width="64" height="64" />



Typescript implementation of the SWF Abstract Syntax Tree (AST).
``shell`Run as a simple user
npm install -S swf-tree
`typescript
import {readFileString} from "fs";
import {Movie} from "swf-tree";
// Deserialize
const jsonString: string = readFileString("ast.json").toString("utf8");
const parsedJson: Movie.Json = JSON.parse(jsonString);
const movie: Movie = Movie.Type.read("json", parsedJson);
// Serialize
const emittedJson: Movie.Json = Movie.Type.write("json", movie);
console.log(JSON.stringify(jsonMovie, null, 2));
``