diff --git a/backend/graph.js b/backend/graph.js new file mode 100644 index 0000000..91f84f0 --- /dev/null +++ b/backend/graph.js @@ -0,0 +1,26 @@ +// @flow + +export type ID = { + pluginName: string, + repositoryName: string, + name: string, +}; + +export type GraphNode = { + id: ID, + edges: ID[], + payload: T, +}; + +export type GraphEdge = { + id: ID, + sourceId: ID, + destId: ID, + weight: number, + payload: T, +}; + +export type Graph = { + nodes: {[stringID: string]: GraphNode}, + edges: {[stringID: string]: GraphEdge}, +};