1.0.0 • Published 3 years ago
simple-routing v1.0.0
Simple routing
// Endpoints list
const viewsArray = [
{path: '/', view: '<p>Lorem ipsum</p>', title: "lorem"},
{path: '/test', view: 'test', title: "wow"}
];
// 404 Page
const err404 = '<h1 style="font-size: 35pt;" align="center">404</h1>'
// Routing initiation
routing(viewsArray, err404)