Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- app.use(express.static(path.join(__dirname, 'public')));
- project_root/
- node_modules/
- public/
- static/
- node_modules/ # symlinked directory
- # symlink node_modules to public directory
- rm -rf "${postinstall_pwd}/public/static/*"
- rm -rf "${postinstall_pwd}/public/static/node_modules"
- mkdir -p "${postinstall_pwd}/public/static"
- ln -s "${postinstall_pwd}/node_modules" "${postinstall_pwd}/public/static"
- app.use(express.static(path.join(__dirname, 'public')));
- app.use(express.static(path.join(__dirname, 'node_modules')));
Add Comment
Please, Sign In to add comment