I wrote the best text formatting library ever, can we make something out of it?
I'm the author of a text formatting library, s9e\TextFormatter. It's a PHP library that handles various markup via plugins. It supports BBCodes, Markdown, a configurable subset of HTML, emoticons and a bunch of other things. It's fast, configurable and extensible. You can read a more complete description in this document.
I'm looking into Vanilla to see whether it would be a good idea to integrate s9e\TextFormatter, either by creating a plugin for it or possibly as an alternative formatter. From a technical standpoint, I've examined a couple of plugins and I haven't seen anything to make me think it would be impossible, or harder than existing plugins. From a community standpoint though, I have no idea. I've known about Vanilla for a long time but I don't use it and I don't follow your community closely enough to know what users want.
And I guess that where you can help. Is there a need for a better BBCode engine? A different Markdown implementation? Are there markup-related features that are not getting implemented because the software isn't there?
The benefits of using s9e\TextFormatter in Vanilla would be:
- Better performance
- Cost to add new features greatly reduced
- Less potential for incompatibilities between markup(?) -- The plugins are designed to play well together, you don't see emoticons in the middle of a link or a code block, etc...
- That only applies to s9e\TextFormatter plugins
The cost would mostly be in development time I think, although there are some downsides. For instance, other Vanilla plugins could not be applied before s9e\TextFormatter because it could break it. They could be applied after I guess.
The library works differently from what you usually see, too. Things like NBBC or PHP-Markdown transform a text into HTML as a single step. That's why you have to execute them for every post on every page. This library separates parsing from rendering. You run the parser on the user input and store the result (which is XML.) When the post is displayed, you run the renderer on the XML and you get the HTML. It's efficient both in processing time and memory used, and you can still configure the output to change its style, locale, etc...
Anyway, that's the quick rundown. If anybody has any questions, feel free. I love to write walls of text.
- Does it seem like something that the Vanilla community would like to use?
- Is there a developer who knows Vanilla and would be willing to collaborate? Ideally, I'd like to find someone who'd handle interfacing with Vanilla while I'd handle interfacing with s9e\TextFormatter.