Chrome and Edge : Third party partitioning- How to share data now?

Since the browsers have implemented the storage partitioning, we have had issues were we share data with a word addin plugin in an iframe. The temporary work around that we have done right now is to disable the flag for Third party storage partitioning so that the access is still present.

Going forward what would be the best solution to get around this and still have access to the local storage?

From what I understand the solution could be document.requestStorageAccess(); but then as I understand this would prompt the user to provide access. Is this the recommended solution ? Or is there a better way to get around this?