Stuck at 3/5. run just keep spinning


#1


https://www.codecademy.com/courses/react-102/lessons/child-updates-parents-state/exercises/child-parent-pass-handler?action=lesson_resume


I am stuck at 3/5. when I click run it just keeps spinning. It's been like that for the past 3 days. Does anyone know if there are some browser-specific settings I need to configure? I have tried different browsers (Firefox, Chrome and IE) but every time I click on run it just spins and spins. Please help!


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

var Parent = React.createClass({
  getInitialState: function () {
    return { name: 'Frarthur' };
  },
  
  changeName: function (newName) {
    this.setState({
      name: newName
    });
  },

  render: function () {
    return (
    	<Child 
        name={this.state.name} 
        onChange={this.changeName} />
    );
  }
});

ReactDOM.render(
	<Parent />, 
	document.getElementById('app')
);


#2

Please any help? I've not yet figure out how to go pass this section.
I even reset the exercise and click run without making any changes, hoping it will alert the help with code window so i can accept it to provide the correct code, but nada! it just keeps spinning and nothing happens.
Please help, thanks


#3

Parent.js seems alright. Can you post code of your Child.js document ?


#4

Thanks @dayfiri. find my Child.js below.
I actually resetted this exercise and did not modify the Child.js.

var React = require('react');

var Child = React.createClass({
  render: function () {
    return (
      <div>
        <h1>
          Hey my name is {this.props.name}!
        </h1>
        <select id="great-names">
          <option value="Frarthur">
            Frarthur
          </option>

          <option value="Gromulus">
            Gromulus
          </option>

          <option value="Thinkpiece">
            Thinkpiece
          </option>
        </select>
      </div>
    );
  }
});

module.exports = Child;

#5

it's working now! I am not sure i dis anything different...
maybe some setInterval() bug kicking in...:slight_smile:
or some backend angel debugging my profile...
Thanks to who ever did the job :thumbsup:


#6

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