mirror of
https://github.com/rendro/easy-pie-chart.git
synced 2026-10-03 20:56:43 +02:00
Three defects shipped this cycle that neither `npm run build` nor `npm run typecheck` could see, because all three only exist from outside the package: exported types silently degrading to `any` under skipLibCheck when the declarations carried extensionless relative imports, the ESM default import resolving to the module namespace instead of the class, and callbacks being bound at runtime but not typed that way. scripts/verify-package.sh packs the package, installs the tarball into a throwaway project, and typechecks a real consumer against it under node16, nodenext and bundler resolution with skipLibCheck deliberately off, then smoke-tests require(), import, and callback binding at runtime. The fixtures in scripts/package-fixtures include the Readme's gradient example verbatim, so the documented API cannot drift from the shipped types. Verified against both historical failures: reverting the `this` typing or the .js import extensions makes it fail. Runs as its own CI job, once rather than per Node version, since it checks the artifact and not the runtime.