Generate visual representations of the networks underlying video-gamebooks on YouTube https://youtube-maze.delab.re/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

21 lines
565 B

  1. import express from 'express';
  2. import helmet from 'helmet';
  3. import path from 'path';
  4. import cookieParser from 'cookie-parser';
  5. import logger from 'morgan';
  6. import { fileURLToPath } from 'url';
  7. const thisdir = path.dirname(fileURLToPath(import.meta.url));
  8. const app = express();
  9. export default app;
  10. app.use(helmet());
  11. app.use(logger('dev'));
  12. app.use(express.json());
  13. app.use(express.urlencoded({ extended: false }));
  14. app.use(cookieParser());
  15. app.use(express.static(path.join(thisdir, 'public')));
  16. import mazes from './routes/mazes.mjs';
  17. app.use('/mazes', mazes);