Closed Colisan closed 3 years ago
Thanks for handling the formatting! I have to admit that I had no idea how type decorator works and I had trouble setting the index key here (turns out I was missing the extraneous {} around the declaration). I also didn't see the eslint warning, I'll try to setup my VScode better next time! Using the Runewizard links right now, it feels great! I think we could add a target='_blank' for better user navigation and it'd be perfect =)
turns out I was missing the extraneous {} around the declaration
Yes if you meant JSDoc, TS (which parses the code via tsconfig) does not require the {}
in its own implementation of JSDoc @type
however this causes trouble if the type declaration does use them (as in the index type).
I think we could add a target='_blank' for better user navigation and it'd be perfect =)
Sure I've just made the change locally.
Thanks. I did some minor fixes afterwards for JSDoc, and prettier auto-formatting (extension in VSCode). JSDoc is mainly an experiment right now. Not sure it's worth the hassle really I might revert it to a TS project at some point, but it's the only small project I could test with. Althroug the
types.ts
file compiled just fine, the codebase is meant to use only .js files. The types are in .d.ts files so they become globally available for JSDoc declarations in .js files.Thanks for the contribution!