Hello,
I am developing a private app in React using Redux in the ticket side bar of support. I have a store with a provider at the top of my elements' tree.
I create a modal while clicking on a button that fires this snippet of code:
function getModal() {
zafClient.invoke('instances.create', {
location: 'modal',
url: 'assets/index.html',
size: {
width: '80vh',
height: '750px', //500px for purchases history, 750px for purchase details
}
})
.then(function (modalContext) {
//do when the modal is created
var modalClient = zafClient.instance(modalContext['instances.create'][0].instanceGuid);
modalClient.on('modal.close', function () {
//do when the modal is closed
});
});
}
Is there a solution to push the context and the store of my application to the modal when I am creating it?
Thanks for your help
Paul
Would you be able to share a snippet of what the modalContext code looks like as well as where/when you're specifically setting the the state for it?
Before seeing more of your code though, my first thought is to try utilizing localStorage to help persist the desired values of the variables. There's some info on how to do that with ZAF [here](https://developer.zendesk.com/documentation/apps/app-developer-guide/using-the-apps-framework/#using-local-storage).
Hope to hear back from you soon!
Erica - Dev Support