UNPKG

@typed/content-hash

Version:

Content hash a directory of HTML/JS/CSS files and other static assets

10 lines (8 loc) 317 B
import { DiGraph } from './DiGraph' export function removeVertice<A>(vertice: A, graph: DiGraph<A>): DiGraph<A> { return { ...graph, edges: graph.edges.filter((x) => !graph.equals(x[0])(vertice) && !graph.equals(x[1])(vertice)), vertices: graph.vertices.filter((x) => !graph.equals(x)(vertice)), } }