mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-12 20:38:52 +00:00
chore: add noUnusedLocals and noUnusedParameters rules (#3476)
Co-authored-by: LongYinan <lynweklm@gmail.com>
This commit is contained in:
@@ -32,7 +32,7 @@ export const notificationsAtom = atom<Notification[]>(get =>
|
||||
get(notificationsBaseAtom)
|
||||
);
|
||||
|
||||
export const removeNotificationAtom = atom(null, (get, set, key: string) => {
|
||||
export const removeNotificationAtom = atom(null, (_, set, key: string) => {
|
||||
set(notificationsBaseAtom, notifications =>
|
||||
notifications.filter(notification => notification.key !== key)
|
||||
);
|
||||
@@ -40,7 +40,7 @@ export const removeNotificationAtom = atom(null, (get, set, key: string) => {
|
||||
|
||||
export const pushNotificationAtom = atom<null, [Notification], void>(
|
||||
null,
|
||||
(get, set, newNotification) => {
|
||||
(_, set, newNotification) => {
|
||||
const key = newNotification.key;
|
||||
const removeNotification = () =>
|
||||
set(notificationsBaseAtom, notifications =>
|
||||
|
||||
@@ -145,6 +145,7 @@ export class DataDefine<Data extends DataTypeShape = Record<string, unknown>> {
|
||||
interface DataDefineConfig<T extends DataTypeShape> {
|
||||
name: string;
|
||||
supers: DataDefine[];
|
||||
_phantom?: T;
|
||||
}
|
||||
|
||||
interface DataHelper<T extends DataTypeShape> {
|
||||
|
||||
Reference in New Issue
Block a user