Mercurial > code > home > repos > streamed-graph
comparison src/graph_view.ts @ 76:58676ebdce0f
sort and dedup imports
author | drewp@bigasterisk.com |
---|---|
date | Tue, 11 Feb 2020 21:55:35 -0800 |
parents | f7143866fae1 |
children | 0c188ed3bcd8 |
comparison
equal
deleted
inserted
replaced
75:0ba4bd0ba245 | 76:58676ebdce0f |
---|---|
1 import { html, TemplateResult } from "lit-html"; | 1 import { html, TemplateResult } from 'lit-html'; |
2 import { Quad, Term, N3Store, Literal, Quad_Object, NamedNode } from "n3"; | 2 import { DataFactory, Literal, N3Store, NamedNode, Quad, Quad_Object, Term, Util } from 'n3'; |
3 import { DataFactory, Util } from "n3"; | 3 |
4 import { SuffixLabels } from './suffixLabels'; | |
5 | |
4 const { namedNode } = DataFactory; | 6 const { namedNode } = DataFactory; |
5 | 7 |
6 import { SuffixLabels } from "./suffixLabels"; | |
7 import { Quad_Object } from "n3"; | |
8 // import ns from 'n3/src/IRIs'; | 8 // import ns from 'n3/src/IRIs'; |
9 // const { rdf } = ns; | 9 // const { rdf } = ns; |
10 const rdf = { | 10 const rdf = { |
11 type: namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#type") | 11 type: namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#type") |
12 }; | 12 }; |
29 | 29 |
30 let subjType: NamedNode | null = null; | 30 let subjType: NamedNode | null = null; |
31 | 31 |
32 graph.forObjects( | 32 graph.forObjects( |
33 (o: Quad_Object) => { | 33 (o: Quad_Object) => { |
34 subjType = o as NamedNode; | 34 subjType = o as NamedNode; |
35 }, | 35 }, |
36 subj, | 36 subj, |
37 rdfType, | 37 rdfType, |
38 null | 38 null |
39 ); | 39 ); |