eslint Parsing error: Unexpected token =

Why is eslint throwing this error? The Javascript runs without issue inside of React Native. The code was taken from the react-navigation example at :


static navigationOptions = { header: null };

eslint error:

error  Parsing error: Unexpected token =

.eslintrc.js file:

module.exports = {
    "extends": "standard",
    "plugins": [


The syntax is not yet standardised, but a stage-2 proposal for inclusion in Javascript (see “Class Fields” on

Try adding the following option above “extends” in your .eslintrc.js:

"parser": "babel-eslint",

Source: stackoverflow