E2 import
statement and modules
#3200
Denneisk
started this conversation in
Suggestions
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
To add to the growing list of Javascript sins on E2, here's another:
As we all know, the E2 namespace is growing every day, and we have a ton of deprecated functions that don't deserve to exist. For new users, these old functions poison the well of how to do things. For old users, they clog up intellisense and the E2 Helper.
Introducing, (pseudo-)modules:
The main difference here is that the module is symbolic. The runtime has no reference to
fc
, and instead the conversion offc.open
tofile.callback.open
is done at compile-time. This has actually been a long-standing dream of mine, because I hate that every function in E2 is global.Immediate benefits:
Caveats:
Long-term potential:
e2:myModule
.@strict
once adoption is secure.Probably important prerequisites to handle before this:
Beta Was this translation helpful? Give feedback.
All reactions