UNPKG

vue-express-mongo-boilerplate

Version:

Express NodeJS application server boilerplate with Mongo and VueJS

13 lines (10 loc) 295 B
"use strict"; let Hashids = require("hashids"); let config = require("../config"); /** * Create a Hash ID generator by module name. * Use `module` as prefix of the `hashSecret` */ module.exports = function(module, length) { return new Hashids(module + config.hashSecret, length || 10); };