Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add ability to pass options to createPersistedQueryLink #106

Merged
merged 3 commits into from
Oct 19, 2019
Merged

Add ability to pass options to createPersistedQueryLink #106

merged 3 commits into from
Oct 19, 2019

Conversation

matrunchyk
Copy link
Contributor

Rationale:

When query persisting is ON, there might be a need in passing options to the createPersistedQueryLink constructor.

No breaking changes.

@bozzbot
Copy link

bozzbot commented May 27, 2019

Any updates on this? The flag useGETForHashedQueries could also be passed which would enable a client to send (cachable) GET requests to the API.
Btw. Not sure if the enabled flag is really needed, I would keep in line with the apollo-link-persisted-queries options.

@Akryum Akryum merged commit fad559d into Akryum:master Oct 19, 2019
@nether-cat
Copy link
Contributor

This had been open for a while, but I seem to grow my knowledge about Apollo at the very same pace that several advanced features + fixes are being added to vue-apollo. I only discovered the flag useGETForHashedQueries today. Thank you @matrunchyk and also +1 @Akryum for the quick release after having merged ❤️

if (typeof persisting === 'object' && persisting != null) {
persistingOpts = persisting
}
if (persistingOpts.enabled) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If the option persisting has been set to true the persisted query link will not be enabled. The documentation implies otherwise and this also breaks setups from previous versions.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh.. I'll create a PR in a few mins

Copy link
Contributor Author

@matrunchyk matrunchyk Oct 21, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Akryum please take a look on this #242

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants