chore(web): new lint setup (#30020)

Co-authored-by: yyh <yuanyouhuilyz@gmail.com>
This commit is contained in:
Stephen Zhou
2025-12-23 16:58:55 +08:00
committed by GitHub
parent 9701a2994b
commit f2842da397
3356 changed files with 85046 additions and 81278 deletions

View File

@ -1,9 +1,11 @@
import { type Context, type Provider, createContext, useContext } from 'react'
import type { Context, Provider } from 'react'
import { createContext, useContext } from 'react'
import * as selector from 'use-context-selector'
const createCreateCtxFunction = (
useContextImpl: typeof useContext,
createContextImpl: typeof createContext) => {
createContextImpl: typeof createContext,
) => {
return function<T>({ name, defaultValue }: CreateCtxOptions<T> = {}): CreateCtxReturn<T> {
const emptySymbol = Symbol(`empty ${name}`)
// @ts-expect-error it's ok here