This is a built-in middleware function in Express. It serves static files and is based on serve-static. error code example
Example 1: app.use public
app.use(express.static('public'))
app.use(express.static('files'))
Example 2: static file
Static file is any content that can be delivered to an end user without
having to be generated, modified, or processed.