diff --git a/.eslintrc.js b/.eslintrc.js index 886d7a1..c372a7d 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -20,7 +20,6 @@ module.exports = { '@typescript-eslint/strict-boolean-expressions': 'off', 'comma-dangle': ['error', 'only-multiline'], 'no-mixed-operators': 'off', - eqeqeq: 'off', '@typescript-eslint/semi': ['error', 'always'], semi: ['error', 'always'], } diff --git a/src/jsx.ts b/src/jsx.ts index 51bb11a..f9beff7 100644 --- a/src/jsx.ts +++ b/src/jsx.ts @@ -33,7 +33,7 @@ export function jsx (tag: string | FunctionComponent, data: VNodeData | null, .. // tag is a function component return tag(data, flatChildren); } else { - if (flatChildren.length == 1 && !flatChildren[0].sel && flatChildren[0].text) { + if (flatChildren.length === 1 && !flatChildren[0].sel && flatChildren[0].text) { // only child is a simple text node, pass as text for a simpler vtree return h(tag, data, flatChildren[0].text); } else { diff --git a/src/modules/hero.ts b/src/modules/hero.ts index 8f6abda..be72ea0 100755 --- a/src/modules/hero.ts +++ b/src/modules/hero.ts @@ -147,7 +147,7 @@ function post () { setNextFrame(newStyle, 'opacity', '1'); // Animate old element for (var key in (oldVnode as any).savedStyle) { // re-apply saved inherited properties - if (parseInt(key) != key as any as number) { + if (String(parseInt(key)) !== key) { var ms = key.substring(0, 2) === 'ms'; var moz = key.substring(0, 3) === 'moz'; var webkit = key.substring(0, 6) === 'webkit';