ericvicenti / ericvicenti/react-fs-renderer
Inspiration and making it work with "wrapper" component
- Dominant language
- No language data
- Stars
- 112
- Forks
- 2
- PR merge metrics
- No merged PRs in 30d
Description
Hi @ericvicenti ! Thank you for your work.
I'm currently writing [`react-electron-menu`](https://github.com/SamyPesse/react-electron-menu), and I'm trying an approach similar to yours.
But I'm blocked with the [`render`](https://github.com/SamyPesse/react-electron-menu/blob/master/src/render.js), which is similar to your `renderToFS` if my application uses a component like:
```js
class DefaultEditMenu extends React.Component {
render() {
const { children } = this.props;
return (
{children}
);
}
}
```
Basically the render doesn't handle wrapper components.
The same issue will exist with `react-fs-renderer`, if I do something like (not tested):
```js
class ProjectTemplate extends React.Component {
render() {
const { name, children } = this.props;
return (
{children}
);
}
}
class MyProject extends React.Component {
render() {
return (
);
}
}
```
The current rendering logic stops at the children of `MyProject`, and never "render" the `` to get its children.
What will be the best solution to fix this ? Or do you have nay advice on how I can implement `react-electron-menu` ?
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.