How to use node-static.Server:
GitHub: LibreTexts/Libretext
53 54 55 56 57 58 59 60 61 62
// devtools: true, }).then( async (browser) => { const server = http.createServer(handler); const localServer = http.createServer(handler); const staticFileServer = new nodeStatic.Server('./public'); const dbClient = new MongoClient(process.env.MONGODB_URI); const database = dbClient.db(process.env.MONGODB_DB_NAME); const downloadEvents = database.collection('download-events'); let port = 3001;