4.0.0 • Published 9 months ago

lasso-marko v4.0.0

Weekly downloads
2,523
License
MIT
Repository
github
Last release
9 months ago

lasso-marko

NOTE: lasso-marko@4 requires marko >= 5, @marko/compiler >= 5.33 and lasso >= 3. For older versions use lasso-marko@3.

Plugin for the Lasso.js to support compilation and transport of Marko template files. Templates are compiled using the Marko compiler that produces a CommonJS module as output.

Usage

npm install lasso-marko --save

Register the plugin when configuring the lasso. For example:

require('lasso').configure({
    "plugins": [
        ...
        "lasso-marko"
    ]
    ...
});

Required Marko templates will automatically be found via static code analysis when loaded, eg like:

var template = require('./template.marko');

template.render({
        name: 'Frank'
    },
    function(err, output) {
        console.log(output);
    });

To explicitly declare templates that may not be discovered via static code analysis of CommonJS modules, you can also choose to declare Marko template dependencies in an browser.json file.

{
    "dependencies": [
        "marko-dependencies: ./template.marko"
    ]
}

Contributors

Contribute

Pull Requests welcome. Please submit Github issues for any feature enhancements, bugs or documentation problems.

License

Apache License v2.0

4.0.0

9 months ago

3.2.1

2 years ago

3.1.2

2 years ago

3.2.0

2 years ago

3.1.1

3 years ago

3.1.0

3 years ago

3.0.2

3 years ago

3.0.1

3 years ago

3.0.0

3 years ago

2.5.0

4 years ago

2.4.9

4 years ago

2.4.8

5 years ago

2.4.7

5 years ago

2.4.6

6 years ago

2.4.5

6 years ago

2.4.4

6 years ago

2.4.3

6 years ago

2.4.2

6 years ago

2.4.1

6 years ago

2.4.0

6 years ago

2.3.2-0

7 years ago

2.3.1

7 years ago

2.3.0

7 years ago

2.2.2

7 years ago

2.2.1

7 years ago

2.2.0

7 years ago

2.1.0

7 years ago

2.0.7

8 years ago

2.0.6

8 years ago

2.0.5

8 years ago

2.0.4

9 years ago

2.0.3

9 years ago

2.0.2

9 years ago

2.0.1

9 years ago