Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork13
Open
Description
I notice while doing somearch tests that we are wrongly pushing Upper_case_components to the stream while we should pushingnodes
Take the following code as an example:
constBar=()=>{return"Baz"}constFoo=()=>{return(<Bar/>)}constApp=()=>{return(<Foo/>)};const{ pipe}=renderToPipeableStream(<App/>);
Ocaml test code
letnested_upper_case_components()=letapp()=React.Upper_case_component ("app",fun() ->React.Upper_case_component ("Foo",fun() ->React.Upper_case_component ("Bar",fun() ->React.string"Bar")) )inlet output, subscribe= capture_stream()inlet%lwt()=ReactServerDOM.render_model~subscribe (app())in assert_list_of_strings!output ["2:\"Bar\"\n";"1:\"$2\"\n";"0:\"$1\"\n"];Lwt.return()
The result on our current code is:["2:\"Bar\"\n"; "1:\"$2\"\n"; "0:\"$1\"\n"]
While react's result is:0:"Baz"
And that makes sense as the Upper_case_components isn't a content to be pushed, unlike Lower_case_elements / Json values / etc ...
We should change the way we push our content.
Metadata
Metadata
Assignees
Labels
No labels