You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying out Reactjs.Net and i am running into an error. I have chosen to forgo using jsx in favor of plain JS. i am not sure if this is the cause of my problem, but i am following the compiled js examples i have found in the reactjs tutorials. array.map.js is the code found here https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/map. Do i have to use jsx?
the specific error
Error while rendering "BreadCrumbBox" to "react1": Object doesn't support property or method 'map'
Line: 8
Column:9
// SimpleReactor.js
var BreadCrumbBox = React.createClass({
render: function () {
var crumblets = this.props.crumbs.map(function (item, index) {
return BreadCrumb({
crumb: item,
key: index
});
});
return React.DOM.ul({}, crumblets);
}
});
var BreadCrumb = React.createClass({
render: function () {
return React.DOM.ul({},
React.DOM.a({
href: this.props.crumb.Url.toString()
}, this.props.crumb.Text));
}
});
BreadCrumbBox = React.createFactory(BreadCrumbBox);
BreadCrumb = React.createFactory(BreadCrumb);
I am trying out Reactjs.Net and i am running into an error. I have chosen to forgo using jsx in favor of plain JS. i am not sure if this is the cause of my problem, but i am following the compiled js examples i have found in the reactjs tutorials. array.map.js is the code found here https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/map. Do i have to use jsx?
the specific error
Error while rendering "BreadCrumbBox" to "react1": Object doesn't support property or method 'map'
Line: 8
Column:9
the above is my react script.
here is my react config
here is my cshtml page
The text was updated successfully, but these errors were encountered: