Skip to content

require.js plugin for loading templates and injecting them as <script type=text/html> elements

Notifications You must be signed in to change notification settings

One-com/requirejs-tpl

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

36 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Template plugin for RequireJs

NPM version Build Status Coverage Status Dependency Status

Notice! this plugin requires the standard text plugin.

This plugin will allow you to require templates, as employed in KnockoutJS, via the ordinary dependency syntax.

Example:

define([
    'tpl!templates/thing.ko'
], function () {
    [... code ...]
});

The above will fetch the thing.ko file, and insert it into the DOM in a script tag with the id thing.

About

require.js plugin for loading templates and injecting them as <script type=text/html> elements

Resources

Stars

Watchers

Forks

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •