Skip to content
This repository has been archived by the owner on Oct 21, 2021. It is now read-only.

Proposal: Add support for shallow rendering #15

Open
IgnusG opened this issue Sep 22, 2018 · 2 comments
Open

Proposal: Add support for shallow rendering #15

IgnusG opened this issue Sep 22, 2018 · 2 comments

Comments

@IgnusG
Copy link
Contributor

IgnusG commented Sep 22, 2018

Inferno adapter could replace the contents of the component with null which prevents its rendering.

It could then redirect methods which try accessing its internal props, state ... to the host node instead of the rendered nodes (which would be null).

I'm not sure about the implications to lifecycle methods though. Theoretically inferno unmounts a component once it returns null so I would suspect componentWillUnmount and/or componentDidMount not firing predictably.

Have to cross-check with preacts adapters

@eddyerburgh
Copy link
Contributor

I'm happy to take a PR for this, but I won't work on this myself.

@IgnusG
Copy link
Contributor Author

IgnusG commented Sep 22, 2018

No worries, mostly putting it here so I don’t forget the approach. I’m gonnna try implementing it later

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants