1.0.1 • Published 2 years ago

@paroi/express-edge v1.0.1

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

@paroi/express-edge

Use Edge templating engine with Express

This is a fork of express-edge with pull request changes of riccycastro. In addition, we upgrade edge.js package to version 5.3.3.

travis npm version npm downloads npm license prs Welcome eslint

Installation

npm install @paroi/express-edge

Usage

See the Edge documentation for how to structure your templates.

const express = require('express');
const app = express();
const { engine } = require('@paroi/express-edge');

// Automatically sets view engine and adds dot notation to app.render
app.use(engine);
app.set('views', `${__dirname}/views`);

app.get('/', (req, res) => {
  res.render('users.index', { users: [...] });
});

app.listen(3000);

License

MIT © Daniel Eckermann