Both gems 'wdm' and 'rb-kqueue' can be installed on any platform. They fail when require 'wdm' or 'rb-kqueue' is called. So the conditions in the Gemfile can be removed and should not be recommended.
Having conditions in the Gemfile is generally bad practice, since this leads to changed Gemfile.lock, whenever the bundler is executed on a different platform. Also bundle package --all-platforms doesn't work properly, when gems are declared conditionally.
In principle the gems could also be added to the listen.gemspec, like 'rb-fsevent' and
'rb-inotify'. But this would install them for all users of 'listen', although only a small subset needs them.
Both gems 'wdm' and 'rb-kqueue' can be installed on any platform. They fail when require 'wdm' or 'rb-kqueue' is called. So the conditions in the Gemfile can be removed and should not be recommended.
Having conditions in the Gemfile is generally bad practice, since this leads to changed Gemfile.lock, whenever the bundler is executed on a different platform. Also
bundle package --all-platforms
doesn't work properly, when gems are declared conditionally.