forked from booleanhunter/ReactJS-AdminLTE
-
Notifications
You must be signed in to change notification settings - Fork 0
/
routes.js
executable file
·44 lines (31 loc) · 1.04 KB
/
routes.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
function initialize(app){
//These are the API end points that you can write.
//Setting up an event listener for GET request to '/'
app.get('/', function(req, res){
console.log('request to / received');
res.render('dashboard.html');
});
//Routes for rendering original adminlte pages
app.get('/adminlte/index.html', function(req, res){
res.render('adminlte-pages/index.html');
});
app.get('/adminlte/index2.html', function(req, res){
res.render('adminlte-pages/index2.html');
});
/*Routes for rendering pages in reactjs.
After creating a page in react, define a route for it here
*/
app.get('/widgets.html', function(req, res){
res.render('widgets.html');
});
app.get('/buttons.html', function(req, res){
res.render('buttons.html');
});
app.get('/UI/general.html', function(req, res){
res.render('general.html');
});
app.get('/timeline.html', function(req, res){
res.render('timeline.html');
});
}
exports.initialize = initialize;