@nuxtjs/proxy
Advanced tools
Comparing version 1.3.2 to 1.3.3
@@ -5,2 +5,11 @@ # Change Log | ||
## [1.3.3](https://github.com/nuxt-community/proxy-module/compare/v1.3.2...v1.3.3) (2019-03-02) | ||
### Bug Fixes | ||
* **module:** generate warn if not SPA and increase coverage ([#31](https://github.com/nuxt-community/proxy-module/issues/31)) ([8baafc9](https://github.com/nuxt-community/proxy-module/commit/8baafc9)) | ||
## [1.3.2](https://github.com/nuxt-community/proxy-module/compare/v1.3.1...v1.3.2) (2019-02-18) | ||
@@ -7,0 +16,0 @@ |
@@ -15,5 +15,7 @@ const Proxy = require('http-proxy-middleware') | ||
// this.nuxt.hook('generate:before', () => { | ||
// logger.warn('The module `@nuxtjs/proxy` does not work in generated mode.') | ||
// }) | ||
if (this.options.mode !== 'spa') { | ||
this.nuxt.hook('generate:before', () => { | ||
consola.warn('The module `@nuxtjs/proxy` does not work in generated mode.') | ||
}) | ||
} | ||
@@ -20,0 +22,0 @@ // Defaults |
{ | ||
"name": "@nuxtjs/proxy", | ||
"version": "1.3.2", | ||
"version": "1.3.3", | ||
"description": "The one-liner node.js http-proxy middleware solution for Nuxt.js using http-proxy-middleware", | ||
@@ -24,3 +24,3 @@ "license": "MIT", | ||
"dependencies": { | ||
"consola": "^2.4.1", | ||
"consola": "^2.5.6", | ||
"http-proxy-middleware": "^0.19.1" | ||
@@ -45,3 +45,2 @@ }, | ||
"eslint-plugin-vue": "latest", | ||
"get-port": "latest", | ||
"husky": "latest", | ||
@@ -48,0 +47,0 @@ "jest": "latest", |
@@ -34,4 +34,4 @@ # Proxy Module | ||
1. Add `@nuxtjs/proxy` dependency with `yarn` or `npm` into your project | ||
2. Add `@nuxtjs/proxy` to `modules` section of `nuxt.config.js` | ||
1. Add the `@nuxtjs/proxy` dependency with `yarn` or `npm` to your project | ||
2. Add `@nuxtjs/proxy` to the `modules` section of `nuxt.config.js` | ||
3. Configure it: | ||
@@ -43,6 +43,6 @@ | ||
// Simple usage | ||
'@nuxtjs/proxy', | ||
'@nuxtjs/proxy', | ||
// With options | ||
['@nuxtjs/proxy', { pathRewrite: { '^/api' : '/api/v1' } }], | ||
// With options | ||
['@nuxtjs/proxy', { pathRewrite: { '^/api' : '/api/v1' } }] | ||
] | ||
@@ -90,7 +90,7 @@ } | ||
proxy: { | ||
// Simple proxy | ||
'/api': 'http://example.com', | ||
// Simple proxy | ||
'/api': 'http://example.com', | ||
// With options | ||
'/api2': { target: 'http://example.com', ws: false } | ||
// With options | ||
'/api2': { target: 'http://example.com', ws: false } | ||
} | ||
@@ -97,0 +97,0 @@ } |
10859
22
60
Updatedconsola@^2.5.6