← Back to context

Comment by noduerme

8 months ago

The only exception is if you have 500k LOC in a language whose runtime is going to be deprecated on all platforms overnight.

I'm referring to the uh, retrospectively unfortunate decision I made in 2007 to start building large scale business app frontends in AS3.

I guess I should be thankful for the work, having to rewrite everything in TS from scratch a decade later. (At least the backends didn't have to be torn down).

There's a parallel universe where someone convinced you to rewrite it in something else from the start and you spent years on the rewrite instead and it never went anywhere. Could you have done that emergency rewrite without 10 years of becoming an expert in the problem you were solving? The alternative universe has you spending time becoming an expert in a new language instead and maybe not getting anywhere with the rewrite.

  • Totally true. Spending years fine-tuning the business logic and UIs made the eventual rewrites a lot cleaner and faster, having already iterated many times over the years and discovering what worked and what didn't. And learning TS after AS3 was easy enough. The real pain point was switching from a paradigm in which I owned the screen graph down to the pixel-level placement of each component, to a trying to wrangle similar behavior from a mix of DOM elements, relative/absolute positioning and arbitrary stuff drawn into canvases. Particularly for things like interactive Gantt charts and some of the really complicated visualization components that had been a relative pleasure to design and code in Flash. But yeah, it was much easier to learn a new language paradigm knowing exactly what I needed to implement, rather than having to devise the logic at the same time.

I wonder how many businesses suffered the same?

I remember Flash as a complete, straight-to-business platform that allowed me to just focus on getting stuff done.

It was a sound decision back then.

  • I think it was a very sound decision back in 2007 if you wanted to write once and deploy everywhere. In browser, and on the desktop for Windows and Mac. JS wasn't up to the task of complex SPAs or graphic visualizations yet (<canvas> didn't even exist), and the alternative would have been Java apps which relied on whatever runtime the user had installed. The fact that Flash/AIR could deploy with its own runtime or a browser plugin was huge. It allowed an independent coder like me to maintain multiple large pieces of software across multiple platforms at a time when it was almost unheard of to do that without a team.

My current employer, similarly, invested a significant amount of resources into Silverlight. Luckily only one component of the application had been switched to Silverlight, but a significant amount of code was written to be the core of that effort and future components before browsers/MS killed it overnight.