Greasy Fork is available in English.

Diskusie » Spätná väzba ku Greasy Fork

External script code is minified

§
Pridaný: 28.09.2021

Greasy Fork's rules for posted scripts

Code posted to Greasy Fork must not be obfuscated or minified.

Can the code of the external script be obfuscated or minified? External scripts come from allowed websites, but:

  • If the external script is well known, Greasy Fork allows it to contain minified code.
  • If the external script is personally written, Greasy Fork does not allow it to contain minified or obfuscated code.

Since it needs to be dealt with in different situations, Greasy Fork should write these situations into the rules.

JasonBarnabeZablokovaný
§
Pridaný: 28.09.2021

Yes, if an external script comes from an approved source, it can be minified.

§
Pridaný: 29.09.2021

There are obvious loopholes in the rules for external scripts.

  • The script on Greasy For was deleted because of "Minified code", but its code was not deleted. Another script introduces the code of this deleted script, the deleted script comes from an approved source Greasy Fork, so another script does not violate the rules.
  • The script have only the code used to introduce external scripts, no other code. Or the core code of the script comes from external scripts. The external scripts are written by the script author himself. The external scripts are minified. Doing so does not violate the rules.

If the external script is minified, its corresponding project needs at least 2 people to participate, and must reach a certain amount of installation or a certain number of collections. In this way, we can assume that this external script is safe. The rules need to be improved.

The rules do not say that external scripts cannot be obfuscated. So external scripts can be obfuscated. The rules need to be improved.

JasonBarnabeZablokovaný
§
Pridaný: 30.09.2021

The script on Greasy For was deleted because of "Minified code", but its code was not deleted. Another script introduces the code of this deleted script, the deleted script comes from an approved source Greasy Fork, so another script does not violate the rules.

I think this is covered in your own thread. I intended on making deleted code inaccessible.

The script have only the code used to introduce external scripts, no other code. Or the core code of the script comes from external scripts. The external scripts are written by the script author himself. The external scripts are minified. Doing so does not violate the rules.

As mentioned previously, the idea behind allowing external code was to allow the use of common libraries. These libraries are often minified, and this is not an issue.

I'd be open to suggestions on how to differentiate a common library and the case you've identified.

§
Pridaný: 30.09.2021
Upravený: 30.09.2021

My opinion:

  • If the minified external script is a library, it must have function descriptions and usage documents. This proves that it is a library, not a script.
  • If the minified external script is not a library, it is a script. This external script is not allowed to be imported.

I can't find a suitable example for the time being.

§
Pridaný: 02.12.2021

My opinion:

  • If the minified external script is a library, it must have function descriptions and usage documents. This proves that it is a library, not a script.
  • If the minified external script is not a library, it is a script. This external script is not allowed to be imported.

I can't find a suitable example for the time being.

I agree with your opinion.

https://greasyfork.org/en/scripts/14466-gwdang is an exapmple. This main code of user script is on the @require.

Pridať odpoveď

Aby ste mohli pridať odpoveď, prihláste sa.