GitShow/antfu/tsnapi
antfu

tsnapi

Library public API snapshot testing for runtime exports and type declarations.

by antfu
snapshotsnapshot-testing
Star on GitHubForknpm

TypeScript

188 stars3 forks3 contributorsActive · 1h agoSince 2026MIT

Meet the team

See all 3 on GitHub →
antfu
antfu54 contributions
jycouet
jycouet3 contributions

Commit activity

Last 12 weeks · 51 commits

Full graph →

Recent fixes

View closed PRs →
jycouet
feat: surface @deprecated as a minimal marker in snapshotsMergedPR

Closes #25 is part of the public contract, so instead of stripping it with every other comment, a minimal marker is kept on the line above the declaration (runtime + dts). The original message is dropped, so adding/removing the tag shows up in the diff.

jycouet · 2h ago
jycouet
Track deprecated functionsClosedIssue

Clear and concise description of the problem Would be great to have a way to surface methods. Suggested solution When removing comments, if we have a , prefix the function with ? Alternative _No response_ Additional context _No response_ Validations [x] Follow our Code of Conduct [x] Read the Contributing Guide. [x] Check that there isn't already an issue that request the same feature to avoid creating a duplicate. BTW, I'm happy to send a PR 👍

jycouet · 2h ago
jycouet
fix: expand re-exported local declare namespaces in dts snapshotsMergedPR

The dts extractor collects interfaces, type aliases, enums, classes, functions and variables when resolving specifiers, but not (namespaces). So , where is a local , collapses to a bare re-export with no body. This collects into the declaration map, adds a kind (KIND_ORDER, KIND_LABELS, kindFromDeclType), and handles it in by renaming the namespace id to the export alias and prefixing / (mirroring the class/function branches). Includes a regression test.

jycouet · 2h ago
Structured data for AI agents

Repository: antfu/tsnapi. Description: Library public API snapshot testing for runtime exports and type declarations. Stars: 188, Forks: 3. Primary language: TypeScript. License: MIT. Topics: snapshot, snapshot-testing. Open PRs: 0, open issues: 0. Last activity: 1h ago. Top contributors: antfu, jycouet.

·@ofershap

Replace github.com with gitshow.dev