Discussions » Development

Load a script from an external URL

Posted: 2023-01-30

Am I allowed to load a script (library) from an external URL?

I am currently developing a scripting api, which I update regulary and push updates here and then. A lot of greasyfork scripts use this library, and its a pain when I have to update each script with the new library version. Is there anything that I can do?

Posted: 2023-01-31

yes you are, specially because many other scripts already use that library according to you

Which library are you talking about? pls link it here

Posted: 2023-01-31

Yes, you are allowed, but only if you follow going to follow this guide (Greasy Fork's libraries/external libraries' usage policy).

If you want to get the newest version of library from greasy fork, you can just not specify version search parameter, so URL will look like this:


This is not recommended, but if you always want latest version, you can do it.

Example user-script:

// ==UserScript==
// @name User Script
// @namespace -
// @version 1.0.0
// @description description
// @author You
// @match *://*/*
// @run-at document-body
// @license GPL-3.0-or-later
// @grant none
// @require https://greasyfork.org/scripts/456235-moomoo-js/code/MooMoojs.js
Posted: 2023-01-31

I totally forgot about // ==/UserScript== at the end of user-script's meta values. Do not forget to put it at the end! :P

Post reply

Sign in to post a reply.