-
-
Save iwatakeshi/f3ed121b6f40a75cf05bafd9ff0c9730 to your computer and use it in GitHub Desktop.
@nuxt/apollo Cors Issue Apollo config
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apollo: { | |
clientConfigs: { | |
default: { | |
httpEndpoint: `${process.env.API_URL}/graphql`, | |
httpLinkOptions: { | |
fetchOptions: { | |
mode: 'cors' //Cors Needed for external Cross origins, need to allow headers from server | |
}, | |
credentials: "omit" //must be omit to support application/json content type | |
} | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment