In VS Code editor the JSHint tells me that code below has an error.
const pageSubpartsComponents = {
'page-header': PageHeader,
'page-footer': PageFooter
};
const routes = [{
path: '/',
components: {
default: DefaultLayout,
...pageSubpartsComponents
}
}];
...pageSubpartsComponents
has text correction.
The error I get is:
[jshint] Expected '}' to match '{' from line 6 and instead saw 'pageSubpartsComponents'. (E020)
I have .jshintrc file and inside this code:
{
"esversion": 6
}
I know that rest/spread operator is not part of the ES6 but it doesn't allows me to use higher version of ES.
- VS Code v 1.25.0-insider
- jshint v 0.10.19
What else should I use? Does anyone solve this already?