Thread:Talk:Snippets/Make it possible to import the snippets directly

Hi!

I was wondering if wouldn't be better to have the snippets code in real .js pages (e.g. on MediaWiki: namespace, problably as gadgets) so that people could use instead of copying the source from Mediawiki pages. The migration guide suggests we should avoid duplication of code.

In case it is necessary to display the source on documentation page, that could be achieved easily by using something like which results in

which is the content of MediaWiki:Gadget-HotCat.js.