Answer the question
In order to leave comments, you need to log in
How to create a node server that responds to a '/' site based on bootstrap-template?
I downloaded a ready -made one-page site template from the startbootstrap.com site, redesigned it to fit my needs. It is launched using browsersync and gulp. (browsersync.create() is included in the gulpfile.js file).
Now I need to put this whole thing on a server, preferably on Express.js.
What should be my actions?
Answer the question
In order to leave comments, you need to log in
What should be my actions?
var path = require('path');
var express = require('express');
var app = express();
app.use(express.static(path.join(__dirname, './public'))); // если сайт лежит в папке public в корне проекта
app.listen(3000, function () {
console.log('Example app listening on port 3000!');
});
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question