Migrating from React to LightningJS?

Hello! I have a web app built with Next & React. It’s served us very well so far, but in the pursuit of performance, I have begun exploring LightningJS. I’m loving what I’m seeing with Blitz. I’m left wondering, what are some recommended strategies (if any any) for migrating an existing TV web app from React to LightningJS? Thanks!

Hey @spetrey, welcome to the community.

Since you’re current project is an HTML / CSS based app, there is no one-on-one conversion possible.

But given that you have a modern App with reactivity etc., many of the concepts that you know will also apply to your new Lightning 3 Blits app. In fact, an upgrade from Lightning 2 to Lightning 3, would maybe require a larger rewrite as there existed no concept of reactive template updates.

Depending on how your app is currently built, much of the business logic (API calls, video play back integration, etc.) can be reused. So you’re looking mostly at re-doing the view portion part.

Blits draws inspiration from VueJS, so some familiarity with that framework will help you get up and running fast. But also for React developers, Blits has proven to be fairly easy to pick up!

My suggestion would be to get started with a fresh project (npm create @lightningjs/app) and start playing around with that. Check out the docs here: Blits - Lightning 3 App Development Framework | Lightningjs. And make sure to check out the Blits Example app (GitHub - lightning-js/blits-example-app: Example Blits Lightning 3 App) - it’s a great reference for those that love to learn by example.

And feel free to join our helpful Discord community as well: LightningJS

Also - since you’re coming from react you might want to check out the SolidJS integration with Lightning: GitHub - lightning-tv/solid: SolidJS Framework for Lightning Renderer