reactive-python / reactive-python/reactpy

Investigate MorphDOM vs ReactDOM

Open
#883 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

priority-3-low type-investigation
Dominant language
Python
Stars
8.1k
Forks
332
PR merge metrics
No merged PRs in 30d

Description

Currently, due to the addition of our reactpy.html.script tag, there is now the potential of user's manually manipulating the client side DOM, which will cause a mismatch when comparing to the server side VDOM. This can cause client side exceptions within ReactDOM when the attempting to change/modify/add/delete nodes or attributes that no longer exist. We may want to consider switching to MorphDOM to account for this, since it could automatically mutate the client DOM to meet the server side VDOM model.

This issue exists to debate whether MorphDOM should be considered as an alternative, or whether we should simply work around these issues with React-DOM.

Note: Originally discussed in https://github.com/idom-team/idom/discussions/798 by Archmonger August 10, 2022

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing the reactpy.html.script behavior and the original discussion in https://github.com/idom-team/idom/discussions/798. Compare how ReactDOM currently handles client-side DOM changes with the proposed MorphDOM alternative. Done means documenting a clear decision on whether to adopt MorphDOM or address the ReactDOM mismatch another way.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, python, react
Domain
frontend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.