🐛 Update: Added support for the 'find' command in settings.local.json. Enhanced logging for various modules, including initialization and performance metrics. Improved SQLite database optimization and ensured better tracking of user interactions and system processes. 📚
This commit is contained in:
5
network-visualization/node_modules/live-server/middleware/example.js
generated
vendored
Normal file
5
network-visualization/node_modules/live-server/middleware/example.js
generated
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
module.exports = function(req, res, next) {
|
||||
res.statusCode = 202;
|
||||
next();
|
||||
}
|
||||
|
14
network-visualization/node_modules/live-server/middleware/spa-ignore-assets.js
generated
vendored
Normal file
14
network-visualization/node_modules/live-server/middleware/spa-ignore-assets.js
generated
vendored
Normal file
@@ -0,0 +1,14 @@
|
||||
// Single Page Apps - redirect to /#/ except when a file extension is given
|
||||
var path = require('path');
|
||||
module.exports = function(req, res, next) {
|
||||
if (req.method !== "GET" && req.method !== "HEAD")
|
||||
next();
|
||||
if (req.url !== '/' && path.extname(req.url) === '') {
|
||||
var route = req.url;
|
||||
req.url = '/';
|
||||
res.statusCode = 302;
|
||||
res.setHeader('Location', req.url + '#' + route);
|
||||
res.end();
|
||||
}
|
||||
else next();
|
||||
}
|
13
network-visualization/node_modules/live-server/middleware/spa.js
generated
vendored
Normal file
13
network-visualization/node_modules/live-server/middleware/spa.js
generated
vendored
Normal file
@@ -0,0 +1,13 @@
|
||||
// Single Page Apps - redirect to /#/
|
||||
module.exports = function(req, res, next) {
|
||||
if (req.method !== "GET" && req.method !== "HEAD")
|
||||
next();
|
||||
if (req.url !== '/') {
|
||||
var route = req.url;
|
||||
req.url = '/';
|
||||
res.statusCode = 302;
|
||||
res.setHeader('Location', req.url + '#' + route);
|
||||
res.end();
|
||||
}
|
||||
else next();
|
||||
}
|
Reference in New Issue
Block a user