OSX
1.7.0
When providing RenderPageOptions.settings the page should open with those effective, instead of the default values.
const options: RenderPageOptions = {
endpoint: url,
settings: {
'general.betaUpdates': false,
'editor.fontSize': 12,
'editor.fontFamily': "'Menlo', 'Source Code Pro', 'Consolas', 'Inconsolata', 'Droid Sans Mono', 'Monaco', monospace'",
'editor.theme': 'light',
'editor.reuseHeaders': true,
'request.credentials': 'omit',
'tracing.hideTracingResponse': true,
},
version: playgroundVersion,
};
return renderPlaygroundPage(options);
The "settings" are ignored, the page always renders with the default settings, the served HTML actually contains the settings given in code. Tested with Chrome incognito window, not a browser caching issue. Once the page opens it is possible to changes the settings in browser.
Just try to provide any settings to the renderPlaygroundPage or any of the middleware packages.
_Please provide a gif or image of the issue for a quicker response/fix._
I'm seeing this as well, trying the minimal page with 1.7.0
GraphQLPlayground.init(root, {
endpoint: location.protocol + '//' + path,
settings: {
'request.credentials': 'same-origin'
}
})
Settings seem to be ignored both with empty localStorage and after first load -- but can still be changed manually from the interface.
it looks to be writing the settings to the DOM prior to client initialisation but is failing to hydrate the redux store settings from props
Any progress here?
seeing this issue as well when configuring through apollo 2, would like to see this fixed
It should be fixed, if its still problem please reopen.
Most helpful comment
it looks to be writing the settings to the DOM prior to client initialisation but is failing to hydrate the redux store settings from props
https://github.com/prismagraphql/graphql-playground/blob/62ecfdb658935a11391701835d15c66a06be68ad/packages/graphql-playground-react/src/components/GraphQLBinApp.tsx#L42-L51