Back action to notion
Opened this issue · 10 comments
I used my cellphone to open the imamhanafi.com website, but when I returned, instead of returning to the home page, it returned to the notion of login.
Me too!!! But I don't know how to fix this, when I asked gpt it said that it could be caused by fetchAndApply function. But even though it provides some modifications, it doesn't fix the problem very well.
I have the same problem in 2024. Is there any solution?
#258 - Okay so I tried this, and I'm able to navigate back and forth now. But something new is broken, the page doesn't remove my 'slug' (what comes after my domain)
I had the same problem and went to investigate the worker.js
code in Cloudflare.
I don't know the exact reason but here there was a problem with the "dark/light mode toggle" function at __console.environment.ThemeStore.setState()
line.
If you don't care about the "dark/light mode toggle", just delete or comment the call of the function, at this line:
addDarkModeButton(nav ? 'web' : 'mobile');
Clear the cache and the redirection will work again!
But if you want to fix the "dark/light mode toggle", check this issue #258 and update your functions onLight
, onDark
, addDarkModeButton
and add the enableConsoleEffectAndSetMode
function as it is in the issue.
Don't forget to "Save and deploy" in Cloudflare workers after any edit.
I hope it helps :)
[rafaelthz]Thank you very much! Your advice on removing the dark dark line helped.
Any idea why issue #258 would cause the slug to not be removed?
Hey @rafaelthz, thanks for the write-up. Unfortunately deleting the "addDarkModeButton(nav ? 'web' : 'mobile');" line didn't work for me. If I look around on others' linked Fruition websites who said it fixed it, it appears like the problem still exists. Does anyone have any updated solutions to solve this?
one way to fix it is to change this line:
history.replaceState(history.state, 'bypass', '/' + page);
to
window.location.href = '/' + page; return;
Doesn't work for me. Also causing a full page refresh load
Doesn't work for me. Also causing a full page refresh load
is there a site that you can repro this?