Extension: Get list of windows

Hello everybody. All good? I hope so.

I created a summer project to occupy myself a little: an extension for gnome. One of the features I would like my extension to rely on is the ability to list open windows. I did a little research on the subject and found some scarce sources. As stated in this FAQ, gnome does not have a functionality to list open windows, you need to ask the window server, however, as far as possible, I would like the extension to work on both X11 and Wayland. Does anyone know, or recommend, one or more libraries in the JS repositories that have such functionality?

Thank you very much in advance!

Extensions run as part of the GNOME Shell without restrictions, allowing them to directly retrieve the list of open windows from the window manager.
global.display.list_all_windows()
https://gjs-docs.gnome.org/meta13~13/meta.display#method-list_all_windows

Forgive me for the delay. Many thanks for the reply.

This topic was automatically closed 45 days after the last reply. New replies are no longer allowed.