The other answers didn't really work for me while developing my own extension. What did however was:
journalctl /usr/lib/gnome-session/gnome-session-binary -f -o cat
If you want to declutter the output to just see your app, you can use:
journalctl /usr/lib/gnome-session/gnome-session-binary -f -o cat | grep [myAppId]
If you also want to access non error logs using the above method above you can use:
global.log('[myAppId]', valueToLog);
If you don't know the correct path to your gnome session you can also use:
journalctl -f | grep gnome-session
Why it was not working is probably because of my gnome-session-binary path was different, which might be related to a newer version of gnome being installed.
global.log('hello world');
inside a loop in my extension but nothing got logged in the console. Can't the extensions log messages programatically? – Other