Problem with function in render


#1

Hello! Can someone point out why this code is not passing? The instruction is to add a nested h1 inside the div and then inject friend.title. I tried different ways (code in one line, starting code on line 20, ...) but I can't get pass instruction #4.

var Friend = React.createClass({
  render: function () {
    var friend = friends[1];
    return (
      <div>
        <h1>{friend.title}</h1>
      </div>
    );
  }
});

3. Put Logic in a Render Function
#2

Same problem here, frustrating


#3

i have same problem
this is my code:

// New component class starts here:
var Friend = React.createClass({
var friend = friends[1];
  render: function (){
    return (
      <div>
        <h1>{friend.title}</h1>
      </div>
    );
	}
});

#4

Please post a link to the exercise page. Thanks.