Just use path.resolve() method.
import { resolve } from 'path'; app.use('/public/uploads', express.static(resolve('public', 'uploads'))) Just use path.resolve() method.
import { resolve } from 'path'; app.use('/public/uploads', express.static(resolve('public', 'uploads')))