Tiddlywiki PWA does that : Setup your own TiddlyPWA server on Raspberry Pi 5 (using cloudflare tunnel) (you can also use glitch to try it first, it’s free). Once your wiki is setup, you can use it offline and it will sync when it comes back online. The only issue I have with TPWA is that I can’t share my wikis with it in read-only mode.