Fix ESLint errors (#793)
This fixes failing `npm run lint`: - fixes `max-len` issue in code by reformat of the expression - exempt ES6 template literals from `max-len` rule using ESLint configuration change Thanks!
This commit is contained in:
parent
89fa0904af
commit
fe950192e7
2 changed files with 5 additions and 2 deletions
|
@ -20,7 +20,7 @@
|
||||||
"no-console": 0,
|
"no-console": 0,
|
||||||
"no-alert": 0,
|
"no-alert": 0,
|
||||||
"no-underscore-dangle": 0,
|
"no-underscore-dangle": 0,
|
||||||
"max-len": [1, 120, 2, {ignoreComments: true}],
|
"max-len": [1, 120, 2, {"ignoreComments": true, "ignoreTemplateLiterals": true}],
|
||||||
"quote-props": [1, "consistent-as-needed"],
|
"quote-props": [1, "consistent-as-needed"],
|
||||||
"no-unused-vars": [1, {"vars": "local", "args": "none"}],
|
"no-unused-vars": [1, {"vars": "local", "args": "none"}],
|
||||||
"consistent-return": ["error", { "treatUndefinedAsUnspecified": true }],
|
"consistent-return": ["error", { "treatUndefinedAsUnspecified": true }],
|
||||||
|
|
|
@ -81,7 +81,10 @@ class PreviewFrame extends React.Component {
|
||||||
|
|
||||||
handleConsoleEvent(messageEvent) {
|
handleConsoleEvent(messageEvent) {
|
||||||
if (Array.isArray(messageEvent.data)) {
|
if (Array.isArray(messageEvent.data)) {
|
||||||
const decodedMessages = messageEvent.data.map(message => Object.assign(Decode(message.log), { source: message.source }));
|
const decodedMessages = messageEvent.data.map(message =>
|
||||||
|
Object.assign(Decode(message.log), {
|
||||||
|
source: message.source
|
||||||
|
}));
|
||||||
|
|
||||||
decodedMessages.every((message, index, arr) => {
|
decodedMessages.every((message, index, arr) => {
|
||||||
const { data: args } = message;
|
const { data: args } = message;
|
||||||
|
|
Loading…
Reference in a new issue