Electron 12 introduced early Wayland support behind the flags --enable-features=UseOzonePlatform --ozone-platform=wayland.
This gist adds these flags to the .desktop files of the selected Electron packages after every upgrade, so that they can be started from a launcher with Wayland enabled.
Will be deprecated after Electron eventually starts with Wayland by default without needing these flags.
- Copy
electron-wayland.shto/usr/local/sbin/electron-wayland.sh - Add execution permissions to
/usr/local/sbin/electron-wayland.sh(sudo chmod a+x /usr/local/sbin/electron-wayland.sh) - Copy
electron-wayland.hookto/etc/pacman.d/hooks/electron-wayland.hook - Update
electron-wayland.hookwith the Electron packages you'd like to patch automatically
If you save electron-wayland.sh elsewhere, please update Exec in electron-wayland.hook correspondingly
_You may need to create the /etc/pacman.d/hooks/ folder first``