Skip to content

Instantly share code, notes, and snippets.

@videlais
Created Jun 29, 2019
Embed
What would you like to do?
const FileReader = require('extwee/FileReader.js');
const TweeParser = require('extwee/TweeParser.js');
const StoryFormatParser = require('extwee/StoryFormatParser.js');
const HTMLWriter = require('extwee/HTMLWriter.js');
let textfile = "test.twee";
let storyFormat = "format.js";
let outputFile = "example.html";
let fr = new FileReader(textfile);
let tp = new TweeParser(fr.contents);
let sfp = new StoryFormatParser(storyFormat);
let hw = new HTMLWriter(outputFile, tp.story, sfp.JSON);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment