andrewhathaway / Winterfell

Generate complex, validated and extendable JSON-based forms in React.
http://winterfell.andrewhathaway.net
MIT License
785 stars 116 forks source link

Uncaught TypeError: this.props.onRender is not a function #90

Closed tmcdonnell87 closed 7 years ago

tmcdonnell87 commented 7 years ago

Sorry if I'm missing something basic here. I love the idea of using this for my next project, but the boilerplate is throwing an error: Uncaught TypeError: this.props.onRender is not a function

Furthermore, when I change anything, I get Uncaught TypeError: Cannot read property 'bind' of undefined.

Problem is reproduced here: https://esnextb.in/?gist=07a8b8d62af04bb39693f8bae5344a8b. (Open the console to see the errors.)

andrewhathaway commented 7 years ago

Oh wow, this is interesting. I haven't seen this yet. I'll investigate at some point this weekend. Feel free to dig in to the code and submit a PR!

andrewhathaway commented 7 years ago

@tmcdonnell87 I've managed to reproduce and push a fix, however I'll need to publish a new version.

tmcdonnell87 commented 7 years ago

Thanks for the quick response, @andrewhathaway. Upgrading to 1.1.2 did not fix the problem. (As far as I can tell, #848a5113b54d5764b2c9addf1c56ac689d7eccc6 only changed the readme and version number?

andrewhathaway commented 7 years ago

Oh damn, I must have messed something up. Let me see where my code went! :p

andrewhathaway commented 7 years ago

Hi @tmcdonnell87 I've pushed a quick fix. That should fix it, however I think I'll be attempting to move forward with a 2.0 when I can find the time to fix issues like this, add tests, modernise the project and also add new features.