Skip to content

Latest commit

 

History

History
28 lines (20 loc) · 494 Bytes

README.md

File metadata and controls

28 lines (20 loc) · 494 Bytes

requirejs-tpl

Plugin for RequireJS for loading template files via requirejs-text

Requirements

Assumptions

  • templates must be available via same domain, in /templates
  • template files use the .tpl extension

Usage

/templates/hello.tpl

<p>Hello World.</p>
define(['tpl!hello'], function(tpl) {
	document.write(tpl);
});