Related to my solid-auth-client
for SAFE, I have an error in the solid-filemanager
app related to browser history.
I’m wondering if it is SAFE Browser related because I guess it is not happening in clearweb stuff and don’t think it is related to my code.
Anyway, if you know a bit about handling history and getting stuff out of events I’d appreciate your thoughts on this:
https://gitter.im/solid/app-development?at=5d00f3da049bf9263c59e8c9
a quick check in firefox for window.location.state
shows it doesn’t exist for me normally
context from link:
I’m seeing solid-filemanager error because it’s handlePop() (see solid-filemanager/src/Components/HistoryHandler/HistoryHandler.tsx at master · Otto-AA/solid-filemanager · GitHub) is passed location
where location.state
is not defined,
Thanks Josh, the solid-filemanager
code is using a history
module, and that is constructing the location object from an event object (getDOMLocation(historyState)
gets state
from historyState.state
and then uses createLocation(path, state, key)
to create the location
object).
So I was finding it hard to know what that is and what is/isn’t permitted.
Looks like it should be optional though, so useful input.
@joshuef thanks - have found it is a bug in old latest v4.9.0 version of history: it checks if event.state
is undefined
but not for null
! Submitted ReactTraining/history
issue #708
1 Like
This topic was automatically closed after 60 days. New replies are no longer allowed.