Villus GraphQL client integration with Nuxt.js
- Provide Villus client to Nuxt / Vue
Install with yarn:
yarn add nuxt-villus graphql
Install with npm:
npm install nuxt-villus graphql
nuxt.config.js
export default {
modules: ["nuxt-villus"],
villus: {
/**
* GraphQL HTTP endpoint
*/
httpEndpoint: "https://rickandmortyapi.com/graphql",
/**
* GraphQL WS endpoint
*/
wsEndpoint: "wss://rickandmortyapi.com/graphql",
},
}