1

i always get this error message within my React JSX files:

export default class applicationContainer extends React.Component {
    static propTypes = {
        params: React.PropTypes.any,
        route: React.PropTypes.any
    };
    ....

or

componentDidMount = () => {
      ...}

any ideas.

Thx

Timo

1 Answers1

0

I believe the correct syntax should be:

export default class applicationContainer extends React.Component {
    componentDidMount() {
        // ...
    }
};

applicationContainer.propTypes = {
    params: React.PropTypes.any,
    route: React.PropTypes.any
};
  • nope, its not a wrong syntax, just look here: http://stackoverflow.com/questions/29433130/react-statics-with-es6-classes – KaiserKoenig Apr 19 '16 at 07:41