Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

egg-view-vue-es7

gzlock3MIT0.0.2

egg view plugin for vue

egg, eggPlugin, egg-plugin, egg-view, vue, ssr

readme

egg-view-vue

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

egg view plugin for [vue].

Install

$ npm i egg-view-vue-es7 -S

Usage

// {app_root}/config/plugin.js
exports.vue = {
  enable: true,
  package: 'egg-view-vue-es7',
};
// {app_root}/config/config.default.js
exports.vue = {
  // cache: {
  //  max: 1000,
  //  maxAge: 1000 * 3600 * 24 * 7,
  //},
};

Render in controller

// {app_root}/app/controller/test.js
exports.home = async ctx => {
  await ctx.render('home/home.js', { name: 'vue view' });
};

Configuration

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

Questions & Suggestions

Please open an issue here.

License

MIT