问题
I am trying to get a hang of react-data-grid and the examples on their page have a "play around with it" link that takes you to jsfiddle. For some reason, I am unable to see the output on jsfiddle. What would be a solution for this?
回答1:
Some of the dependencies are deprecated in the latest react version used by jsfiddle. On inspecting the resources accessed by their page and comparing it with fiddle, you can hack a solution by doing the following in jsfiddle :
- remove
react-with-addons.js
andreact-dom.js
from external resources tab. - add react.min.js and react-dom.min.js in external resources.
- replace jsfiddle-integration-babel.js in script with this.
Try this fork. It doesn't update contents in table, which is the same state as in page.
来源:https://stackoverflow.com/questions/46923987/how-do-i-run-react-data-grid-examples-on-jsfiddle