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

[graphiql] user-facing setting for persisting headers #2793

Closed
thomasheyenbrock opened this issue Oct 7, 2022 · 2 comments · Fixed by #2895
Closed

[graphiql] user-facing setting for persisting headers #2793

thomasheyenbrock opened this issue Oct 7, 2022 · 2 comments · Fixed by #2895

Comments

@thomasheyenbrock
Copy link
Collaborator

The GraphiQL currently provides a prop shouldPersistHeaders that implementors can use to decide if header values should be persisted in localStorage. By default, no headers are persisted as a security measure (header values often times contain sensitive tokens). This defaults leads to many GraphiQL implementations that are not persisting headers.

As a GraphiQL user I would like to override this setting. I want to be able to choose if I want my headers to be persisted or not.

Proposal: Add a section to the settings dialog where users can override the default behavior of the GraphiQL implementation around persisting headers. This setting should only have effect if the shouldPersistHeaders prop is not set, or in other words, the GraphiQL implementation should still be able to explicitly enforce a choice about persisting headers and GraphiQL users can only choose their preference if the implementation is not explicit about this setting.

@TheMightyPenguin
Copy link
Contributor

Gonna give this one a shot 👀

@TheMightyPenguin
Copy link
Contributor

Found an accessibility issue when working on this one #2891

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

Successfully merging a pull request may close this issue.

2 participants