This repository was archived by the owner on Apr 22, 2026. It is now read-only.
Ts migration#1
Open
Craig Andersen (crander7) wants to merge 5 commits intomasterfrom
Open
Conversation
Wiz Scan Summary
To detect these findings earlier in the dev lifecycle, try using Wiz Code VS Code Extension. |
There was a problem hiding this comment.
Pull request overview
Migrates the library from the previous JS/CRA-based setup to a TypeScript-based build/test toolchain (tsup + vitest + biome) and rewrites the GaugeChart implementation in TS/React.
Changes:
- Added TypeScript build tooling (tsconfig + tsup) and updated package metadata/exports for ESM+CJS publishing.
- Reimplemented
GaugeChartand supporting modules in TypeScript, plus added vitest test coverage. - Removed CRA demo/app assets and previously committed
dist/build artifacts; modernized CI/publish workflows.
Reviewed changes
Copilot reviewed 36 out of 48 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| vitest.setup.ts | Adds jest-dom matchers for vitest. |
| vitest.config.ts | Configures vitest (jsdom, setup file, test include globs). |
| tsup.config.ts | Defines tsup build entry/outputs and externals. |
| tsconfig.json | Adds strict TS compiler configuration for the library and tooling. |
| src/serviceWorker.js | Removes CRA service worker helper. |
| src/logo.svg | Removes CRA demo asset. |
| src/lib/index.ts | Adds TS entry point exports for the library. |
| src/lib/index.js | Removes previous JS entry point. |
| src/lib/GaugeChart/utils.ts | Adds TS utilities for layout, arcs, and text. |
| src/lib/GaugeChart/utils.js | Removes previous JS utilities. |
| src/lib/GaugeChart/useDeepCompareEffect.ts | Adds a TS deep-compare effect hook used for update control. |
| src/lib/GaugeChart/types.ts | Adds exported TS types for props/refs/d3 selections. |
| src/lib/GaugeChart/renderChart.ts | Adds TS chart rendering logic for arcs. |
| src/lib/GaugeChart/renderChart.js | Removes previous JS chart rendering module. |
| src/lib/GaugeChart/index.tsx | Adds TSX GaugeChart implementation. |
| src/lib/GaugeChart/index.js | Removes previous JS GaugeChart implementation. |
| src/lib/GaugeChart/drawNeedle.ts | Adds TS needle drawing/animation logic. |
| src/lib/GaugeChart/drawNeedle.js | Removes previous JS needle module. |
| src/lib/GaugeChart/customHooks.js | Removes previous lodash-based deep-compare hook. |
| src/lib/GaugeChart/tests/utils.test.ts | Adds unit tests for gauge utilities. |
| src/lib/GaugeChart/tests/GaugeChart.test.tsx | Adds component-level tests for GaugeChart. |
| src/index.js | Removes CRA app entry. |
| src/index.css | Removes CRA app styles. |
| src/Icon.js | Removes CRA demo Icon component. |
| src/App.test.js | Removes CRA demo test. |
| src/App.js | Removes CRA demo app. |
| src/App.css | Removes CRA demo styles. |
| public/manifest.json | Removes CRA web app manifest. |
| public/index.html | Removes CRA HTML template. |
| package.json | Updates package for TS build, ESM+CJS exports, peer deps, scripts, and tooling deps. |
| dist/index.js | Removes committed build output. |
| dist/GaugeChart/utils.js | Removes committed build output. |
| dist/GaugeChart/renderChart.js | Removes committed build output. |
| dist/GaugeChart/index.js | Removes committed build output. |
| dist/GaugeChart/drawNeedle.js | Removes committed build output. |
| dist/GaugeChart/customHooks.js | Removes committed build output. |
| biome.json | Adds biome formatter/linter configuration. |
| README.md | Updates docs for new TS fork/tooling/usage and props. |
| .vscode/settings.json | Adds editor configuration aligned with biome. |
| .vscode/launch.json | Removes old CRA Chrome launch config. |
| .nvmrc | Pins Node version for local dev consistency. |
| .gitignore | Updates ignores for new tooling/output (including dist). |
| .github/workflows/npm-publish-github-packages.yml | Modernizes publish workflow and Node version. |
| .github/workflows/ci.yml | Adds CI job for typecheck/lint/test/build on PRs/pushes. |
| .babelrc | Removes old Babel build configuration. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.