package
Static file server that works with HTML5 Pushstate.
npm install pushstate-serverGitHub-flavored package documentation.
Across all versions.
Download trend unavailable.
Runtime metadata.
Tagged topics.
Static file server that works with HTML5 Pushstate.
For example, the route /some/pushstate/route will return the index.html file. But, /some/static/path/logo.png will return the logo.png static file.
npm install pushstate-server --savevar server = require('pushstate-server');
server.start({
port: 3000,
directory: './public'
});or for multiple directories
var server = require('pushstate-server');
server.start({
port: 4200,
directories: ['./public', './bower_components']
});or bind to a particular host
server.start({
port: 4200,
host: '192.99.100.01',
directories: ['./public', './bower_components']
});npm install -g pushstate-serverusage: pushstate-server [directory] [port] [file]port
process.env.PORT if not specified, and defaults to port 9000 if none is availabledirectory
publicfile
index.htmlEstimated unpacked size across 32 packages.
1.0 MB
Includes dependencies.
5 direct · 4 outdated
3.6.6
3.7.0
1.2.0
1.2.8
1.7.3
1.8.2
1.13.2
2.2.1
2.0.0
2.0.0