diff --git a/client/src/App.tsx b/client/src/App.tsx index a5e2bd39..45422328 100644 --- a/client/src/App.tsx +++ b/client/src/App.tsx @@ -111,12 +111,13 @@ function App() { useEffect(() => { // Wait for preferences to be loaded if (!loaded) { return } + console.debug(`width: ${width}`) const _mobile = width < 800 if (!preferences.saveInLocalStore && _mobile !== preferences.mobile) { setPreferences({ ...preferences, mobile: _mobile }) } - }, [width]) + }, [width, loaded]) // Setting up the editor and infoview useEffect(() => { diff --git a/server/bubblewrap.sh b/server/bubblewrap.sh index 8060b052..278f42ae 100755 --- a/server/bubblewrap.sh +++ b/server/bubblewrap.sh @@ -3,9 +3,9 @@ ELAN_HOME=$(cd $1 && lake env printenv ELAN_HOME) (exec bwrap\ - --bind $1 /project \ - --bind $ELAN_HOME /elan \ - --bind /usr /usr \ + --ro-bind $1 /project \ + --ro-bind $ELAN_HOME /elan \ + --ro-bind /usr /usr \ --dev /dev \ --proc /proc \ --symlink usr/lib /lib\