Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

serve static files from express

const path = require('path')
app.use('/static', express.static(path.join(__dirname, 'public')))
Source by expressjs.com #
 
PREVIOUS NEXT
Tagged: #serve #static #files #express
ADD COMMENT
Topic
Name
3+1 =