Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/webdeveric/assemble-helper-assets-manifest
This package provides a custom helper for Handlebars that Assemble can use.
https://github.com/webdeveric/assemble-helper-assets-manifest
assembler assets-manifest handlebars manifest
Last synced: about 1 month ago
JSON representation
This package provides a custom helper for Handlebars that Assemble can use.
- Host: GitHub
- URL: https://github.com/webdeveric/assemble-helper-assets-manifest
- Owner: webdeveric
- License: mit
- Created: 2016-04-13T22:21:16.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2024-06-16T15:53:10.000Z (5 months ago)
- Last Synced: 2024-10-01T15:28:17.839Z (about 1 month ago)
- Topics: assembler, assets-manifest, handlebars, manifest
- Language: JavaScript
- Homepage:
- Size: 156 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: readme.md
- License: LICENSE
Awesome Lists containing this project
README
# Assemble Helper Assets Manifest
[![Build Status](https://travis-ci.org/webdeveric/assemble-helper-assets-manifest.svg?branch=master)](https://travis-ci.org/webdeveric/assemble-helper-assets-manifest)
[![codecov](https://codecov.io/gh/webdeveric/assemble-helper-assets-manifest/branch/master/graph/badge.svg)](https://codecov.io/gh/webdeveric/assemble-helper-assets-manifest)
[![dependencies Status](https://david-dm.org/webdeveric/assemble-helper-assets-manifest/status.svg)](https://david-dm.org/webdeveric/assemble-helper-assets-manifest)
[![devDependencies Status](https://david-dm.org/webdeveric/assemble-helper-assets-manifest/dev-status.svg)](https://david-dm.org/webdeveric/assemble-helper-assets-manifest?type=dev)This package provides a [custom helper](http://assemble.io/docs/Custom-Helpers.html) for
[Handlebars](http://handlebarsjs.com/) that [Assemble](http://assemble.io/) can use.## Installation
```shell
npm install assemble-helper-assets-manifest --save
```## Setup with Assemble
After you install this package, you need to tell Assemble about it.
You do that by adding the package name to the `helpers` array in your config.You also need to specify `assetsManifest` so that the helper knows where
to look for your assets manifest file.**Example config**
```js
assemble: {
options: {
helpers: [ 'assemble-helper-assets-manifest' ],
manifestPath: path.join(__dirname, 'manifest.json')
}
}
```## Setup with Handlebars
```js
var Handlebars = require('handlebars');
var AssetsManifestHelper = require('assemble-helper-assets-manifest');AssetsManifestHelper.register(Handlebars, {
manifestPath: path.join(process.cwd(), 'public', 'assets', 'manifest.json'),
prefix: '/assets/'
});
```## Using the Handlebars helper
```hbs
``````hbs
{{#each images}}
{{/each}}
```