Security News
Weekly Downloads Now Available in npm Package Search Results
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.
fasti-router
Advanced tools
Simple and easy to use express like router for fastify
import {Router} from "fasti-router";
import fastify from "fastify";
const app = fastify();
const router = new Router();
router.use([async function (req, res, next) {
return next(new Error('catched error'));
}, (req, res, next) => {
console.log('use 2');
next();
}]);
// express like error handling
router.use((err, req, res, next) => {
res.end(JSON.stringify({success: true, message: `err: ${err.message} catched`}));
});
router.get('/hello-world', async function (req, res) {
res.send({hello: "world"});
});
router.providedIn(app);
app.listen(8000, (err, address) => {
if (err) {
throw err;
}
console.log(`server listening on ${address}`)
});
FAQs
Simple and easy to use express like router for fastify
The npm package fasti-router receives a total of 5 weekly downloads. As such, fasti-router popularity was classified as not popular.
We found that fasti-router demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.
Security News
A Stanford study reveals 9.5% of engineers contribute almost nothing, costing tech $90B annually, with remote work fueling the rise of "ghost engineers."
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.