Compare commits

..

No commits in common. "f6db8a896934975837fbb44aa29687ff4064e2d9" and "907b0ef30735dc1f58f78ceaff9ae08ba2fbd815" have entirely different histories.

7 changed files with 1 additions and 1337 deletions

1
.gitignore vendored
View File

@ -1 +0,0 @@
node_modules/

View File

@ -1,35 +0,0 @@
// Import things
const express = require('express');
const { is } = require('express/lib/request');
const res = require('express/lib/response');
const app = express();
const path = require('path');
const server = require('http').createServer(app);
const port = process.env.PORT || 3430;
var fs = require('fs');;
// Database for the demo site,
var demoDB = [
{
name: "Poggere"
}
];
// Use /Public as the path for css and such
app.set('views', __dirname + '/../Templates');
app.set('view engine', 'ejs');
app.use(express.static(__dirname + 'Public'));
// Main page
app.get('/', function(req, res){
res.render('app', {site:1, db: demoDB});
});
// Simple way to expose a function
exports = module.exports = rws;
function rws() {
server.listen(port, () => {
console.log('✅ Webserver is running ( %d )', port);
});
};

View File

@ -1 +0,0 @@
<h1>Hello world!!!</h1>

View File

@ -1,2 +1 @@
var rws = require("./Components/webserver.js"); include("./webserver.js")
rws();

1292
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -1,6 +0,0 @@
{
"dependencies": {
"ejs": "^3.1.8",
"express": "^4.18.1"
}
}

0
webserver.js Normal file
View File