You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Was just working on porting Oni2 over to the latest Revery + Brisk reconciler, and reminded me of the context issue. We're using context right now to provide a context-based ThemeProvider.
A potential API could look like:
createContext: 'a -> context('a)
Hooks.useContext: context('a) -> 'a
getProvider: context('a) -> providerComponent('a)
I believe handling the typing correctly in terms of passing the nested context down will be challenging - so we might need to alter the API to make it workable in a strongly-typed environment w/o resorting to Obj.magic.
Not a blocker, I'll workaround it, but just wanted to log an issue to start the discussion.
The text was updated successfully, but these errors were encountered:
Was just working on porting Oni2 over to the latest Revery + Brisk reconciler, and reminded me of the context issue. We're using context right now to provide a context-based
ThemeProvider
.A potential API could look like:
createContext: 'a -> context('a)
Hooks.useContext: context('a) -> 'a
getProvider: context('a) -> providerComponent('a)
I believe handling the typing correctly in terms of passing the nested context down will be challenging - so we might need to alter the API to make it workable in a strongly-typed environment w/o resorting to
Obj.magic
.Not a blocker, I'll workaround it, but just wanted to log an issue to start the discussion.
The text was updated successfully, but these errors were encountered: