项目作者: w0d

项目描述 :
Extend javascript with symbol literals
高级语言: JavaScript
项目地址: git://github.com/w0d/js-symbol-literals.git
创建时间: 2018-01-31T11:58:37Z
项目社区:https://github.com/w0d/js-symbol-literals

开源协议:MIT License

下载


js-symbol-literals

Extend javascript with symbol literals

when symbol use is heavy - code gets peppered with lots of
Symbol.for(‘mySymbolName’)

borrowing from Lingo’s symbol literals, you can type instead

mySymbolName

calling main(scriptText) will convert all occurances of symbol literals eg #symbolName to valid javascript Symbol.for(‘symbolName’)

currently experimental as needs much testing, currently fails if your javascript uses regular expression literals containing the # character