Examples and guides for using the OpenAI API
import js from "@eslint/js"
import pluginNext from "@next/eslint-plugin-next"
import eslintConfigPrettier from "eslint-config-prettier"
import pluginReactHooks from "eslint-plugin-react-hooks"
import globals from "globals"
import tseslint from "typescript-eslint"
/** @type {import("eslint").Linter.Config} */
export default [
{
ignores: [
".next/**",
"coverage/**",
"next-env.d.ts",
"node_modules/**",
],
},
js.configs.recommended,
eslintConfigPrettier,
...tseslint.configs.recommended,
{
languageOptions: {
globals: {
...globals.browser,
...globals.serviceworker,
},
},
},
{
plugins: {
"@next/next": pluginNext,
},
rules: {
...pluginNext.configs.recommended.rules,
...pluginNext.configs["core-web-vitals"].rules,
},
},
{
plugins: {
"react-hooks": pluginReactHooks,
},
rules: {
...pluginReactHooks.configs.recommended.rules,
},
},
]