by problems · 9y ago · 0 comments
The biggest problem isn't just that, it's that those big frameworks change fairly frequently too.
I've witnessed web projects go from backbone to angular to react in the span of a year.
I'm mainly a Qt dev, however I needed to add a Cesium component to the application I'm working on. What a mess. Everything about the javascript ecosystem seems to be in a constant state a flux. I tried to make it better with Typescript, but after trying that for ages I realized I was only complicating things for myself, many of my libraries didn't ship typescript definitions, the main one I was working with needed to be generated based on the documentation and once that was done was severely lacking in much of its functionality.
From crashing editors that wipe your files to dependencies that have breaking updates every few days. And there's a dozen options for everything, at least 5 different module loading systems, of which I had to use several in order to get something compatible with both Cesium and node since both use different module formats and I needed a loader that would support both.
Then there's the packing tools which didn't support what I wanted to do at all without a lot of manual hacks.
Eugh, I don't want to touch it again, the whole thing just made me feel incompetent and thrown around.
But I know I have to, and now I'm sitting here asking myself if React or Backbone would help clean up some messy UI code...
Might be the relatively reasonable size of the projects I have going. But it works well for a lot of stuff.
I think a lot of the problem comes from fear of projects becoming obsolete. Ultimately JS/CSS/HTML isn't going to fundamentally transform in short order.
That said, having built a Backbone app, and then gotten into React+Redux, I'm all in on React and Redux as a better way to build apps. It's a much more consistent mental model, and makes tracing data flow much easier.
I'm actually hoping to write a blog post in the next few weeks discussing how to use Cesium with React+Webpack: basic setup, using React to render Cesium primitives, and then advanced Webpack setup for code splitting.