Poof v0.4.0 Release Notes

Poof 0.4.0 will add a few bells and whistles to your JavaScript and CSS views.

First, syntax highlighting powered by highlight.js has been added to both views. Passage source code doesn’t (and likely won’t ever) get syntax highlighting, though.

Second, a shiny new “lint” button has been added to the JavaScript view. This button uses a client-side, CDN-hosted version of JSHint to help you debug your JavaScript code. It requires a web connection on at least the first use, though the script should cache itself for future offline usage.

This version also includes a critical bug fix for compatibility with Tweego, which expects formats to be valid JSON, not just JavaScript (which is totally fair, mind you). Currently, the v0.3.x format files return a valid JavaScript object that is not valid JSON, which was unwise on my part and only implemented to save a few bytes.

In future 0.4.x versions:

A few patches will be released over the next few days/weeks to make the linter story format-aware to prevent false positives with certain code.

As always, I intend to keep on top of any bugs or weirdness, too.

In later versions:

Depending on the reaction to the linting feature, a similar CSS validation feature may arrive in a future version, though validating CSS in the client-side may prove enough of a challenge that it may get pushed off to a later version or abandoned. JavaScript linting is a much bigger deal anyway, in my opinion.

The PDF export option may get off-loaded to a CDN like the linter, meaning it will work as a cache-able script rather than being built in. This will massively reduce the size of poof, but may not be worth it based on how often this feature is used.

At some point in the future, poof will go through a mild refactor of its codebase and build process to make it easier to work with, particularly for other devs. This will happen sometime prior to the full 1.0.0 release.

I’m considering reworking the codebase to use node modules and webpack (or similar) as well, but such a refactor would increase the format’s size by a not insignificant margin, and only mildly help devs work on it, so I’m not convinced this is the right way to go.