Idea: leave type annotations as comments
- Lingua principale
- JavaScript
- Stelle
- 33
- Fork
- 2
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Descrizione
I tried out Gear on a little tinkering project over the weekend (https://github.com/bmakuh/quip-mass-exporter/blob/master/index.js#L16) and I found myself continuing to comment out the type annotations so I could just run my script directly in Node rather than having to compile it first. What would you think about the possibility of having Gear parse type annotations in comments? That way it would continue to remain standards-compliant JS while gaining the ability to be type-checkable.
You could do something like require the line to start with triple slashes `///` or something so that you wouldn't have to parse _every_ comment, and you could limit it to only comments directly above a function definition or assignment.
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
Valutazione
Questa issue non è ancora stata valutata.