Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

when <RowDefinition> children contains <ColumnDefinition> and an array of <ColumnDefinition> #836

Open
JaosnHsieh opened this issue Oct 14, 2018 · 0 comments

Comments

@JaosnHsieh
Copy link

JaosnHsieh commented Oct 14, 2018

Griddle version

1.13.1

Expected Behavior

Work as flat array of <ColumnDefinition> is flat elements.

Actual Behavior

TypeError: Cannot read property 'id' of undefined

Steps to reproduce

const data = [
  {
    name: "data1",
    name1: 111,
    name2: 222
  },
  {
    name: "data2",
    name1: 333,
    name2: 444
  }
];
class App extends Component {
  render() {
    return (
      <Griddle data={data} plugins={[plugins.LocalPlugin]}>
        <RowDefinition>
          <ColumnDefinition id={"name"} title={"name"} />
          {["name1", "name2"].map(c => {
            return <ColumnDefinition key={c} id={c} title={c} />;
          })}
        </RowDefinition>
      </Griddle>
    );
  }
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant