homepage.js/routes/articles.js

21 lines
539 B
JavaScript
Raw Normal View History

2023-02-22 14:55:17 +01:00
const handler = require('express-async-handler');
const Helpers = require('../helpers');
2023-03-02 14:36:01 +01:00
const db = require('../models');
2023-02-22 14:55:17 +01:00
const Sequelize = require('../models');
2023-08-17 13:03:26 +02:00
function articles(req, res) {
2023-03-11 16:54:53 +01:00
res.template('articles/articles.pug', {
2023-08-17 13:03:26 +02:00
current_route: res.originalUrl
2023-03-11 16:54:53 +01:00
});
2023-03-02 14:36:01 +01:00
}
2023-08-17 13:03:26 +02:00
function manga(req, res) {
res.template('articles/manga.pug', {
current_route: res.originalUrl
})
2023-03-02 14:36:01 +01:00
}
2023-02-22 14:55:17 +01:00
module.exports = (router) => {
router.get('/articles', handler(articles));
2023-08-17 13:03:26 +02:00
router.get('/articles/manga', handler(manga));
2023-02-22 14:55:17 +01:00
}