Join GitHub today
Improve server side only rendering #497
This PR fixes two issues with rendering server side ONLY components:
For example, consider the following code:
Before the fix this resulted in the following HTML:
despite the serverOnly = true argument
After this fix the component will be rendered like this:
This should fix #340
@dustinsoftware fixed! If you wonder why I changed some of the test assertions it's because they made more sense that way. Passing true to either clientOnly or serverOnly, but not both at the same time.
Ideally, maybe those parameters should be joined to an enum or something instead. I.e enum RenderMode: ClientAndServer, ClientOnly, ServerOnly.
I didn't want to introduce too big changes though so I left it like it was.