Skip to content
Myr

chore(eslint): enable `@typescript-eslint/unbound-method` (#2622)

Before adoption: this commit came in with the history the project adopted, so no landing records it.

* chore(eslint): enable `@typescript-eslint/unbound-method` * denoify

authored by Yusuke Wada · committed by GitHub · parent cb24160 · Browse files · 8 files+19 added−0 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

8 files+19 added−0 removed

  • tests:+1 added−0 removed
  • other:+18 added−0 removed

8 files+19 added−0 removed

modified:deno_dist/helper/css/index.ts+1 added
modified:deno_dist/jsx/dom/css.ts+1 added
131 unmodified lines
132export const createCssContext = ({ id }: { id: Readonly<string> }) => {133 const [cssObject, Style] = createCssJsxDomObjects({ id })134135 const newCssClassNameObject = (cssClassName: CssClassName): string => {136 // eslint-disable-next-line @typescript-eslint/unbound-method137 cssClassName.toString = cssObject.toString138 return cssClassName as unknown as string139 }140
71 unmodified lines
added:runtime_tests/tsconfig.json+7 added
modified:src/helper/css/index.ts+1 added
99 unmodified lines
100 ;(className as HtmlEscapedString).isEscaped = true101 ;(className as HtmlEscapedString).callbacks = [addClassNameToContext]102 const promise = Promise.resolve(className)103 Object.assign(promise, cssClassName)104 // eslint-disable-next-line @typescript-eslint/unbound-method105 promise.toString = cssJsxDomObject.toString106 return promise107 }108
80 unmodified lines
modified:src/helper/ssg/ssg.test.tsx+1 added
1/* eslint-disable @typescript-eslint/unbound-method */2import { beforeEach, describe, expect, it } from 'vitest'3import { Hono } from '../../hono'4// eslint-disable-next-line @typescript-eslint/no-unused-vars5import { jsx } from '../../jsx'
624 unmodified lines
modified:src/jsx/dom/css.ts+1 added
131 unmodified lines
132export const createCssContext = ({ id }: { id: Readonly<string> }) => {133 const [cssObject, Style] = createCssJsxDomObjects({ id })134135 const newCssClassNameObject = (cssClassName: CssClassName): string => {136 // eslint-disable-next-line @typescript-eslint/unbound-method137 cssClassName.toString = cssObject.toString138 return cssClassName as unknown as string139 }140
71 unmodified lines
added:.eslintignore+1 added
1.eslintrc.cjs
modified:.eslintrc.cjs+6 added