Repository navigation
v0.2.0
Minor Changes
-
7f47388: New export
@a11ign/toolchain/js-to-tsand binjs-to-ts:npx --yes --package @a11ign/toolchain js-to-tsrenames a repository's.mjs/.cjs/.jssources to.ts(git mv), converts their JSDoc to annotations with TypeScript'sannotateWithTypeFromJSDocfix, rewrites every path that named a renamed file (imports become./x.ts), runstsc --noEmit, and prints the residue by file and error code.--exclude <path>(repeatable) skips a file or directory,--dry-runwrites nothing, a second run changes nothing, and the files edited outside the converted set are printed.typescript6.x is now an optional peer dependency; the command refuses under TypeScript 7, which has no JavaScript API.The
js-to-tsbin begins with#!/usr/bin/env node, so the one-linenpx --yes --package @a11ign/toolchain js-to-tsform runs withoutnodein front.