Despite the importance of on-wiki code (gadgets, site scripts and user scripts) to our projects, there are no guidelines on how to write code in skins, extensions in a way that supports these users.
The lack of guidelines historically has created unnecessary conflict between editors and Wikimedia developers. For example, the common task of changing a class name can cause havoc with certain gadgets that depend on associated styles.
Another significant pain point, is now that we are tracking JavaScript errors across our projects, broken gadgets have become more of a problem, as they make it harder for us to find and triage errors in existing user workflows.
I have spoken to various developers across MediaWiki extensions and it seems pretty clear to me that a policy would be helpful for establishing expected norms.
I've begun drafting a policy based on the discussions I've been having with Wikimedia engineers on:
https://www.mediawiki.org/wiki/User:Jdlrobson/Extension:Gadget/Policy and am inviting Wikimedia developers who build skins or extensions, and gadget developers to engage in the existing talk page topics and bring up new topics. You can also reply directly to me, either personally or publically if you have any feedback you want me to consider.
Thanks in advance for your participation in this process.