Not sure if it isn’t the case, but it seems the only way to export symbols
right now is:
```js
export default { [Symbol(“something”)]: blah }
```
It would be nice if “symbol literals” could somehow be supported. In
particular, I can imagine this sort of thing becoming common:
export { “5.4” as Symbol(“version”) }
Or, even better (but harder since its now more expression):
import VersionSymbol from “symbols"
export { “5.4” as VersionSymbol }
I’m currently writing an API where there are expected methods stored in
symbols, but this forces exporting one default object instead of being able
to lay them out individual.
Thanks,
Francisco
--
Francisco Tolmasky
www.tolmasky.com
[email protected]
_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss