mrombout / asciihero

An AsciiDoc.js extension to help authoring Fighting Fantasy style (and more) gamebooks.
https://mrombout.github.io/asciihero/
MIT License
0 stars 0 forks source link

Online version? #13

Closed mrombout closed 1 year ago

mrombout commented 1 year ago

Perhaps it could be nice to offer an online version that takes AsciiHero documents and converts them to the export formats. It could be a simple REST API, or perhaps even a full-fledged editor with the functionality built-in.

mrombout commented 1 year ago

Asciidoctor.js actually works in the browser with some limitations according to the docs such as the missing support for using a TemplateConverter. If that is the case, I think we should definitely go for an online editor which can convert the on-page editor into HTML or PDF.

Editor

There are several advanced code editors that can be embedded with relative ease such as Ace (from Cloud9 IDE), Monaco (from VSCode), or CodeMirror.

Because of the native support Ace might be the best one to start with.

Preview

I think the Asciidoctor.js API returns HTML, so the easiest way to go about this is probably to just render than HTML in a separate view on the same page.

I am not sure if it's also possible to use asciidoctor-web-pdf in the browser. If so, it would be great if we could generate a PDF and preview that instead of the HTML.

Features

mrombout commented 1 year ago

Closing, it's too much trouble for now and I'm certainly not going to use it that way.