feat(linting): add eslint

This commit is contained in:
moklick
2022-08-08 13:34:00 +02:00
parent f5c8a89582
commit 7150e0369e
72 changed files with 531 additions and 130 deletions
+4 -4
View File
@@ -1,5 +1,5 @@
import { MouseEvent } from 'react';
import { GetState, SetState } from 'zustand';
import { StoreApi } from 'zustand';
import { HandleElement, Node, Position, ReactFlowState } from '../../types';
import { getDimensions } from '../../utils';
@@ -33,7 +33,7 @@ export const getHandleBounds = (
export function getMouseHandler(
id: string,
getState: GetState<ReactFlowState>,
getState: StoreApi<ReactFlowState>['getState'],
handler?: (event: MouseEvent, node: Node) => void
) {
return handler === undefined
@@ -55,8 +55,8 @@ export function handleNodeClick({
}: {
id: string;
store: {
getState: GetState<ReactFlowState>;
setState: SetState<ReactFlowState>;
getState: StoreApi<ReactFlowState>['getState'];
setState: StoreApi<ReactFlowState>['setState'];
};
unselect?: boolean;
}) {