I\'m writing a piece of code currently in tampermonkey and I can\'t work out why i get this error in the console of google chrome,\"Execution of script \'PalaceBOT\' failed! $ i
Get the jQuery from window object
var $ = window.jQuery;
You need to include JQuery $ is not part of regular javascript
I didn't find a better answer other than this.
In general, this chunk of code defines the library for further usage inside tampermonkey editor.
/*globals MY_LIB*/
using this will take off all warnings.
For more information check this (https://jshint.com/docs/#inline-configuration). It explains what globals are, and how do they work.