Skip to content

Conversation

@the-matrixneo
Copy link
Contributor

This PR improves how the rml template function

  • Updated the rml template parsing logic in parser.ts

  • Added a new test in parser.test.ts to verify that { value: 0 } expressions are rendered as 0, preventing regressions and clarifying expected behavior.

  • Improved inline documentation and code comments in parser.ts .

Please merge it under Hacktoberfest2025 and level as you wish.

Thank You!

@bolt-new-by-stackblitz
Copy link

Review PR in StackBlitz Codeflow Run & review this pull request in StackBlitz Codeflow.

@dariomannu
Copy link
Contributor

I believe the fix might be a bit simpler, along the lines of just changing || to ?? where sinks are parsed, because we only want to capture objects that look like a BehaviorSubject with an initial or current .value, if that makes sense...

@the-matrixneo
Copy link
Contributor Author

the-matrixneo commented Oct 2, 2025

Thanks for the guidance @dariomannu ! I've updated the code to use the nullish coalescing operator (??). and made the new PR #49 for issue #43. Please check it out.

@dariomannu dariomannu merged commit 6e80040 into ReactiveHTML:master Oct 3, 2025
@dariomannu
Copy link
Contributor

There we go, excellent, that's merged!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants