Skip to main content

Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags
(+6)

Rebuilding our website... in Superpowers!

Since we're going to be redoing our website for the open source launch, rather than do things the old fashioned way, I started working on a static website project type for Superpowers today. It outputs good old HTML5 and CSS when you export!

I built editors for Jade (HTML templating) and Stylus (CSS with nesting support), reusing the collaborative text editor widget Bilou wrote. It is powered by CodeMirror on the frontend and his operational-transform library on the backend.

I had to implement a couple of terrible hacks to virtualize the filesystem for Jade and Stylus compilation, hot-swapping the default implementation of fs.readFileSync just before calling their render functions. It sucks, I'm not proud (ok maybe just a little bit) but it works and it's just a few lines so it should be easy to improve later on! Jade 2.0 will provide a proper virtual filesystem, whenever it comes out, hopefully Stylus will follow suit.

Next up: images, i18n

I think I'll be adding an editor for uploading images, webfonts or any other blobs that you might want to have on your websites. Then probably a JSON editor and some kind of customizable wiring for making localized websites.

Hopefully it'll all work out and SparklinLabs.com will be built with Superpowers by the end of December. That would be preeeetty cool!

(+1)

This is gonna be epic :D

I've been using Bitbucket to host my site for a few months. It's just a simple static page with links, but using Superpowers it'd be way simpler to make some changes and use SourceTree to upload it. My current method is to make changes, wait for the site to update in around 5-20 mins and make more changes. (another reason my site hasn't been updated since I first designed it in June)