chore: Update eslint and prettier configurations

This commit is contained in:
Jin Yucong 2024-07-05 14:19:53 +08:00
parent c63c9b5c8a
commit 5b1aaee605
24 changed files with 826 additions and 38 deletions

2
ui/.eslintignore Normal file
View file

@ -0,0 +1,2 @@
node_modules
dist

View file

@ -1,3 +1,3 @@
{
"extends": "next/core-web-vitals"
"overrides": []
}

5
ui/.prettierrc Normal file
View file

@ -0,0 +1,5 @@
{
"endOfLine": "auto",
"trailingComma": "all",
"arrowParens": "avoid"
}

View file

@ -1,11 +0,0 @@
/** @type {import("prettier").Config} */
const config = {
printWidth: 80,
trailingComma: 'all',
endOfLine: 'auto',
singleQuote: true,
tabWidth: 2,
};
module.exports = config;

View file

@ -2,7 +2,7 @@
import DeleteChat from '@/components/DeleteChat';
import { formatTimeDifference } from '@/lib/utils';
import { BookOpenText, ClockIcon, Delete, ScanEye } from 'lucide-react';
import { BookOpenText, ClockIcon } from 'lucide-react';
import Link from 'next/link';
import { useEffect, useState } from 'react';

View file

@ -1,3 +1,4 @@
/* eslint-disable @typescript-eslint/no-explicit-any */
'use client';
import { useEffect, useRef, useState } from 'react';