Skip to content

Instantly share code, notes, and snippets.

@joselo
Created May 23, 2015 00:48
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save joselo/ac67e69d1bcf18bb7967 to your computer and use it in GitHub Desktop.
Save joselo/ac67e69d1bcf18bb7967 to your computer and use it in GitHub Desktop.
Proxy webpack api
// package.jon
"scripts": {
"start": "webpack-dev-server --hot"
}
// webpack.config.js
module.exports = {
...
devServer: {
contentBase: PATHS.app,
noInfo: true, // --no-info option
hot: true,
inline: true,
proxy: {
"/api/v1/*": "http://localhost:9292"
}
}
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment