I created a Gtk.Application that has several Gtk.ApplicationWindows. The problem is that, under Wayland, the dash shows one icon per window, no mattering that it is a single application. Under X11 it shows a single icon.
Is it possible to show a single icon in Wayland too?
Have you followed the check list available on the wiki?
The most important part is that your application must have a desktop file installed either under XDG_DATA_DIRS/applications (system-wide) or XDG_DATA_HOME/applications (user).
There’s nothing particularly wrong with dumping a .desktop file into ~/.local/share/applications. If it’s associated with a proper executable, which later disappears, so should the menu(s) entry.