Skip to content
Simple presenter class that can be extended and can load CSS and templates.
JavaScript Shell HTML CSS
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.
test
.gitignore
.npmignore
.travis.yml
LICENSE
README.md
build-tasks.js
build.sh
package.json
presenter.js

README.md

presenter.js

Build Status

Simple presenter class that can be extended and can load CSS and templates.

Example Usage

define([
    "presenter",
    "text!./MyModule.html",
    "text!./MyModule.css"
], function(Presenter, template, style) {

    return Presenter.extend({
        template: template,
        style: style,

        init: function(options) {
            this.el.textContent = options.message;
        }

    });

});
var instance = new MyModule({
    message: "Hello World!"
});
instance.attach(document.body);
Something went wrong with that request. Please try again.