Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/jamiewinder/systemjs-plugins

A few useful SystemJS loader plugins for loading various resources
https://github.com/jamiewinder/systemjs-plugins

Last synced: about 1 month ago
JSON representation

A few useful SystemJS loader plugins for loading various resources

Awesome Lists containing this project

README

        

# systemjs-plugins
A few useful SystemJS loader plugins for loading various resources

## hbs

Basic Handlebars template loading, exports the template function

##### test1.hbs
```
Hello, {{name}}!
```
##### index1.js
```
var hbs = require("./test1.hbs!");
alert(hbs({name: "World"}));
```

## hbss

Loads a number of Handlebars templates from a HTML file, exports a hash of template functions keyed by 'id'.

##### test2.html
```

Hello, {{name}}

Goodbye, {{name}}

```
##### index2.js
```
var hbs = require("./test2.html!hbss");
alert(hbs.hello({name: "World"}));
alert(hbs.goodbye({name: "World"}));
```

## css-inline

Loads CSS as text and inserts it as a `` rather than referencing in a `<link>`.