Map in JSX, 13/16

This is my code:

var React = require('react');
var ReactDOM = require('react-dom');

var people = ['Rowe', 'Prevost', 'Gare'];

var peopleLIs ={
  // return statement goes here:
	return <li>{person}</li>;

// ReactDOM.render goes here:
ReactDOM.render = (<ul>{peopleLIs}</ul>, document.getElementById('app'))

Im getting this error
After your variable declarations, make sure you start a new line with ReactDOM.render().

Please post a link to this exercise. Thank you.

I found the problem and cant remember what exercises it was.

ReactDOM.render = (<ul>{peopleLIs}</ul>, document.getElementById('app'))
Was wrong, it should be
ReactDOM.render(<ul>{peopleLIs}</ul>, document.getElementById('app'))

1 Like

I knew you would spot it on a closer look. We lose focus when looking at something too long. Taking a break and returning later gives us a fresh set of eyes. Good that you spotted your error!

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.