2016-06-24 00:29:55 +02:00
|
|
|
import { Router } from 'express';
|
2016-06-19 00:33:49 +02:00
|
|
|
const router = new Router();
|
2016-06-24 00:29:55 +02:00
|
|
|
import path from 'path';
|
2016-06-19 00:33:49 +02:00
|
|
|
|
2016-06-24 00:29:55 +02:00
|
|
|
// this is intended to be a temporary file
|
2016-06-19 00:33:49 +02:00
|
|
|
// until i figure out isomorphic rendering
|
|
|
|
|
2016-06-24 00:29:55 +02:00
|
|
|
router.route('/').get((req, res) => {
|
|
|
|
res.sendFile(path.resolve(`${__dirname}/../../index.html`));
|
2016-06-19 00:33:49 +02:00
|
|
|
});
|
|
|
|
|
2016-06-24 00:29:55 +02:00
|
|
|
router.route('/signup').get((req, res) => {
|
|
|
|
res.sendFile(path.resolve(`${__dirname}/../../index.html`));
|
2016-06-19 00:33:49 +02:00
|
|
|
});
|
|
|
|
|
2016-06-24 00:29:55 +02:00
|
|
|
router.route('/projects/:project_id').get((req, res) => {
|
|
|
|
res.sendFile(path.resolve(`${__dirname}/../../index.html`));
|
2016-06-19 00:33:49 +02:00
|
|
|
});
|
|
|
|
|
2016-06-24 00:29:55 +02:00
|
|
|
router.route('/login').get((req, res) => {
|
|
|
|
res.sendFile(path.resolve(`${__dirname}/../../index.html`));
|
2016-06-19 00:33:49 +02:00
|
|
|
});
|
|
|
|
|
2016-06-24 00:29:55 +02:00
|
|
|
export default router;
|