LearnNewsExamplesServices
Frontmatter
id7131
titleDev Mode: Main Thread Addon for Live Parsing
stateClosed
labels
enhancement
assigneestobiu
createdAtJul 30, 2025, 1:01 PM
updatedAtAug 2, 2025, 2:58 PM
githubUrlhttps://github.com/neomjs/neo/issues/7131
authortobiu
commentsCount1
parentIssue7130
subIssues[]
subIssuesCompleted0
subIssuesTotal0
blockedBy[]
blocking[]
closedAtAug 2, 2025, 2:58 PM

Dev Mode: Main Thread Addon for Live Parsing

Closed v10.3.0 enhancement
tobiu
tobiu commented on Jul 30, 2025, 1:01 PM

Description: For development mode, we need an addon that can parse these HTML string templates on the fly within the browser. This allows for rapid development and testing without requiring a build step after every change.

Implementation Details:

  • Name: Neo.main.addon.HtmlStringToVdom
  • Method:
    1. Use the native DOMParser to convert the HTML string into a standard DOM tree.
    2. Traverse the generated DOM tree and map it to a JSON structure that matches the Neo.mjs VDOM format.
    3. Ensure that any embedded logic or dynamic values from the template literal are correctly placed within the resulting VDOM for later processing by the framework.
tobiu assigned to @tobiu on Jul 30, 2025, 1:01 PM
tobiu added parent issue #7130 on Jul 30, 2025, 1:01 PM
tobiu added the enhancement label on Jul 30, 2025, 1:01 PM
tobiu referenced in commit d0bd744 - "Main Thread Addon for Live Parsing #7131 base class" on Jul 30, 2025, 11:21 PM
tobiu referenced in commit dd6731c - "#7131 main.addon.HtmlStringToVdom: WIP" on Jul 31, 2025, 12:03 AM
tobiu referenced in commit 92fb035 - "#7131 main.addon.HtmlStringToVdom: using Neo.createStyleObject()" on Jul 31, 2025, 12:15 AM
tobiu referenced in commit 1ffee33 - "Dev Mode: Main Thread Addon for Live Parsing #7131" on Aug 2, 2025, 2:57 PM
tobiu
tobiu Aug 2, 2025, 2:58 PM

Status: Dropped

Reason: This approach was superseded by the in-worker parsing strategy (Sub-Task 4). The main thread addon would require an inefficient and slow worker roundtrip for parsing, while the in-worker approach is synchronous and significantly more performant for the zero-builds development mode. The addon and its related tests have been deleted to simplify the codebase.

tobiu closed this issue on Aug 2, 2025, 2:58 PM