mozilla

Revision 231415 of Template:DekiScript:Page

  • Revision slug: Template:DekiScript:Page
  • Revision title: Template:DekiScript:Page
  • Revision id: 231415
  • Created:
  • Creator: lmorchard
  • Is current revision? No
  • Comment
Tags: 

Revision Content

<% module.exports = buildAPI({ initialize: function (options) { BaseAPI.prototype.initialize.call(this, options); // Incomplete list of Page vars, but probably good enough. // See also: this.setVars({ date: new Date(env.modified), id: env.id, language: env.locale, name: env.slug, path: env.path, tags: env.tags, title: env.title, uri: env.url }); } }); %>

Revision Source

<% module.exports = buildAPI({
    
    initialize: function (options) {
        BaseAPI.prototype.initialize.call(this, options);
        
        // Incomplete list of Page vars, but probably good enough.
        // See also: <http://developer.mindtouch.com/en/docs/DekiScript/Reference/Wiki_Functions_and_Variables/Page>
        this.setVars({
            date: new Date(env.modified),
            id: env.id,
            language: env.locale,
            name: env.slug,
            path: env.path,
            tags: env.tags,
            title: env.title,
            uri: env.url
        });
    }
 
}); %>