eggjs/egg-view-handlebars

Name: egg-view-handlebars

Owner: egg

Description: egg view plugin for handlebars

Created: 2017-02-25 15:23:33.0

Updated: 2018-05-22 02:52:45.0

Pushed: 2018-01-16 02:00:33.0

Homepage: null

Size: 55

Language: JavaScript

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

egg-view-handlebars

NPM version build status Test coverage David deps Known Vulnerabilities npm download

egg view plugin for handlebars

Install
m i egg-view-handlebars --save
Usage
app_root}/config/plugin.js
rts.handlebars = {
able: true,
ckage: 'egg-view-handlebars',

s
app_root}/config/config.default.js

iew
member
property defaultViewEngine: string setup default view engine
property defaultExtension: string template file extension
property mapping: Object {string: string}

rts.view = {
faultViewEngine: 'handlebars',
faultExtension: '.hbs',
pping: {
'.hbs': 'handlebars',


Register Partial

Partials are loaded from app/view/partials by default, you can define user_message.hbs and use userMessage as partial.

Note:

Configuration

see config/config.default.js for more detail.

Questions & Suggestions

Please open an issue here.

License

MIT


This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.