#geordi - address element default values
1 messages · Page 1 of 1 (latest)
This is supported only on create, not update -- those docs are for create
Hm strange, they do work on refresh though if i populate them via sessionStorage or similar
it just throughs the warning
throws*
I'll keep using it as is, as it's the wanted behaviour - just wanted to silence the warning
Hm ok well perhaps it works, but the integration error is telling you it might not work for you in future. If you're using something like that it may change without warning.
On refresh you'd be re-creating the element though
so are you sure its not just working in create as documented?
ah that's likely why then
geordi - address element default values
but why would it throw the warning when the create and update are rendering the same element (Address element via react stripe package)
Sure it sets the default values when first mounted, then decides it's an update and throws the warning - but nothing has really changed
Are you storing your options used during create and passing in the same values to an update somewhere?
It sounds like you might just be passing extra params to the update that aren't needed/supported
I guess it's changing the options.defaultValues when I change the state of the component and it reads them again (since the values change) so it's fine on the create, then when i change a value it re-renders the defaultValues
yep thats it
notice the warning each time I change the value
Then i'm not so concerned for the warning - I'm using the default values correctly on create, just not when I'm updating the values but no real impact