diff --git a/index.d.json.ts b/index.d.json.ts new file mode 100644 index 0000000..57edf6c --- /dev/null +++ b/index.d.json.ts @@ -0,0 +1,14 @@ +export interface Tag2Link { + /** OSM tag key */ + key: `Key:${string}`; + /** URL template or formatter URL: replace `$1` with the tag value */ + url: string; + /** Source of this formatter URL */ + source: `${'wikidata' | 'osm'}:P${number}`; + /** Rank or relative importance of this formatter URL */ + rank: 'preferred' | 'normal' | 'deprecated'; +} + +declare const exports: Tag2Link[]; + +export default exports; diff --git a/package.json b/package.json index 98f172b..3220959 100644 --- a/package.json +++ b/package.json @@ -10,6 +10,7 @@ "url-template" ], "main": "index.json", + "types": "index.d.json.ts", "scripts": { "build": "npx ts-node build.ts" },