[HELP] Is there a way to add Global JS/CSS files?

Hi there,

There are some lines (e.g in the scoreboard resource) like the following:

<script src="nui://game/ui/jquery.js" type="text/javascript"></script>

Is there any way to add custom global JS files, like JQuery, by yourself? I searched the whole Server & Client directory, but couldn’t find a hint where this jquery file is coming from.


Your resource is referenced as nui://[resource name], as well, so if you have a resource called ‘dogfood’ you can import a file from it using nui://dogfood/food.js.

Alright got it, and I guess game/ui/jquery.js is something hardcoded into FiveM itself? Because I can’t find it as a normal resource

It’s in citizen/ui.rpf.

1 Like

Perfect, Thanks for the quick answers! :smile: