Syntax highlighting?

Just a quick test of a syntax highlighting plugin, using some code I’ve grabbed from a small project I’ve begun on github:

var oojs = (function() {

    function initialiseClass(base) {
        base.extend = function (child) { return inheritClass(base, child) };
        return base;
    }

    function inheritClass(base, child) {
        child.prototype = Object.create(base.prototype);
        child.prototype.constructor = child;

        child.extend = function(child2) { return inheritClass(child, child2) };

        return child;
    }

    return {
        init: initialiseClass,
        inherit: inheritClass
    };
})();

Seems to work!

Share Your Thoughts