Slowki / react-golden-layout

A React wrapper around GoldenLayout
MIT License
25 stars 11 forks source link

Cannot update during an existing state transition (such as within `render`). Render methods should be a pure function of props and state. #2

Open Eli-leo opened 6 years ago

Eli-leo commented 6 years ago

I'm trying to use react-golden-layout but I'm getting this error: Cannot update during an existing state transition (such as withinrender). Render methods should be a pure function of props and state.

Would you please show a full example how to use it?

my code: ` render() {

return (
  <GoldenLayout
    className="goldenLayout"
  >
    <Row>
      { {createGoldenLayoutComponent(IncrementButtonContainer, {
        isClosable: false,
        title: "Foo's Title"
      })} }
    </Row>
  </GoldenLayout>
);

}`

It's saying that I can not use it in the render function. Also where I can pass the config for the golden layout?

AndyOGo commented 5 years ago

I have the same issue

alexkreidler commented 5 years ago

Same issue. Any updates? Is this still maintained?

Exchizz commented 5 years ago

Same issue...

nimahkh commented 5 years ago

this repo is not stable , it's not trustable

Exchizz commented 5 years ago

I ended up using the following branch, it works: https://github.com/Slowki/react-golden-layout/tree/fix/state-transition-update