type-link
v0.0.1
Published
Retrieve type definitions from a URL
Readme
type-link
EXPERIMENTAL: Retrieve type definitions from a URL (like Deno)
Installation
npm install --global type-linkCLI Usage
(npx / bunx) type-link <operation> <options>Operations
cache <filename> [--clear] [--reload]- cache http(s) type-imports (import "https://../type.d.ts";)
version- prints version and cache location
usage- prints usage
Examples
Checkout the examples folder on GitHub.
// index.ts
import type { KeyLike } from 'https://deno.land/x/[email protected]/types.d.ts';Make sure you're inside your project's root directory.
Cache all type-imports used by "index.ts"
type-link cache ./index.tsReload and cache all type-imports used by "index.ts"
type-link cache ./index.ts --reloadClear global cache
type-link cache --clear