Hi good people!
So, per that recent thing on reddit:
I wanted to post here.
- We love Elm!
- We really, really love Elm!
- We have (as of today) 22,844 lines of Elm code in production. (https://sgim.com) (still in soft-launch mode, but check it out…)
We seem to have two, maybe three, use cases that might not work under Elm 0.19, so I thought I’d post them here so the core elm team can comment or at least be aware of them.
- FIle upload. We need to allow a client to upload account statements, documents, pdfs, etc. to us. We implemented this using a native module.
- Form input formatting. For example, if someone types in a SSN, we turn 123456789 into 123-45-6789 as they type. Same with dates, dollar values, phone numbers, etc. We use cleave.js as well as a native module to do this. (We spent many hours trying to do this w/o resorting to native code, but ultimately had to go that route.)
- Phoenix sockets. This package is an effect manager. https://saschatimme.github.io/elm-phoenix/
That’s pretty much it.
Although the native code is only 140 lines of JS, it is critical, and we would not upgrade to Elm 0.19 without a way to accomplish the same end result.
With respect to the Phoenix sockets library, that’s how our front-end communicates with our server (running Phoenix/Elixir), so obviously we couldn’t upgrade unless that was working in Elm 0.19.
Rock on, and thank you for writing Elm in the first place!
Adam
ps having said all this, I love Elm so much I’d probably just stick with it anyway at 0.18! It’s that good. We have yet to encounter a true bug in 0.18, and have never had an issue we couldn’t work around either via ports or native code. Literally, the only complaint I have are compile times, which can be quite long if changing a module used by lots of other modules or if doing a full-compile.
pps happy to take this offline, or on slack or whatever.
. Migrating will be the opportunity for us to improve perfs/ux using webworkers (md5 large files is messing with the main thread, and each window is responsible for its upload), but the basics is sending the drop event as elm Value to ports, then use Evaporate.js to manage the queue/retries/paralleled. For the rest of the Native, it’ll be either ports or custom elements.