1.0.0 • Published 4 years ago

fastify-slugify v1.0.0

Weekly downloads
-
License
MIT
Repository
-
Last release
4 years ago

fastify-slugify

Simple plugin to work with Slugify within Fastify. Supports all features from slugify.

Install

npm i fastify-slugify

Usage

const fastify = require('fastify')();

fastify.register(require('fastify-slugify'));

fastify.get('/', async function (req, res) {
  let data = fastify.slugify('some string');
  return res.send(data);
});

fastify.listen(3000, (err) => {
  if (err) throw err;
  console.log(`server listening on ${fastify.server.address().port}`);
});

License

Licensed under MIT.

1.0.0

4 years ago