The easiest way is to install Spectator from AppCenter
If you're using Flatpak install it with
$ flatpak install flathub com.github.treagod.spectator
Then run it with
$ flatpak run com.github.treagod.spectator
If you are on an Ubuntu derivate, you can build and install Spectator as follows
$ sudo apt install valac meson libgee-0.8-dev libgranite-dev \
libgtksourceview-3.0-dev libwebkit2gtk-4.0-dev libjson-glib-dev \
libxml2-dev duktape-dev git cmake libsqlite3-dev
$ git clone https://github.com/treagod/spectator.git
$ cd spectator
$ meson build --prefix=/usr
$ cd build
$ ninja
$ sudo ninja install