Drop dependency on React

Created on 7 July 2020, over 4 years ago
Updated 12 July 2024, 4 months ago

Lightning Scheduler's UI code was originally written in React because there was an internal goal for Lightning to write something, anything, in React. Maybe not the best reason, in retrospect, to have used React.

The truth is, React is much too heavy for the UI implemented by this module. The client-side UI could probably be much more maintainable and flexible if it were in plain JavaScript.

So let's do that -- rewrite the UI code in something less complex than React. I think we should first port it to Backbone, which may be outdated as hell, but at least it's in core and allows us to drop an external dependency. Then later, we can try to factor out Backbone as well and go to plain JavaScript.

πŸ“Œ Task
Status

Closed: won't fix

Version

1.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States phenaproxima Massachusetts

Live updates comments and jobs are added and updated live.
  • JavaScript

    Affects the content, performance, or handling of Javascript.

Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • πŸ‡ΈπŸ‡°Slovakia kaszarobert

    Since then, Backbone will be dropped from Drupal core #3258931: Deprecate backbone and tag it internal β†’ , so that's not a great idea to move from a popular JS framework to an older one that no one uses anymore. Also, dropping React and will make the JS more complicated as the templating would be needed to done with all kinds of query selectors. We're talking about 9 kB + 14 kB JS files that is used on forms, so the size is also not a problem. I simply do not see any advantages we get with that whole rewrite, so we won't be doing this.

Production build 0.71.5 2024