I believe there is changes required on Writing Anki Add-ons , however I am not sure which one. I just got a question asking for help to create an add-on, and was surprised to see this as an example today.
The code at Writing Anki Add-ons seems more up to date, and so I suspect that the part about javascript should either be deleted, or at least rewritten to use current hooks and explain how to add js file.