Install pinned dependencies from package-lock.json
npm run build
Compile src/ into lib/ with TypeScript declarations and source maps
npm test
Run the full Vitest suite once (used by CI)
npm run test:watch
Run Vitest in watch mode — re-runs affected tests on file change
npm run test:coverage
Run Vitest once and produce a coverage report under coverage/
npm run test:typecheck
Type-check the test/ tree with TypeScript using test/tsconfig.json (run on CI)
npm run lint
Lint the codebase with ESLint (flat config in eslint.config.mjs)
npm run lint:fix
Auto-fix lint issues where possible
TypeScript configs
tsconfig.json — production build of src/ → lib/ only
test/tsconfig.json — extends the main config, adds vitest/globals types and includes the test/ tree so the IDE recognizes describe / it / expect in tests
Tests
Tests live under test/ and are executed by Vitest in a Node environment (no browser). The configuration is in vitest.config.mts.
Contributing
Read our contribution guideline to find out how to contribute bugs fixes and improvements
Microsoft Power BI visuals TypeUtils
Usage
Learn how to install and use the TypeUtils in your custom visuals:
Development
Common scripts:
npm cipackage-lock.jsonnpm run buildsrc/intolib/with TypeScript declarations and source mapsnpm testnpm run test:watchnpm run test:coveragecoverage/npm run test:typechecktest/tree with TypeScript usingtest/tsconfig.json(run on CI)npm run linteslint.config.mjs)npm run lint:fixTypeScript configs
tsconfig.json— production build ofsrc/→lib/onlytest/tsconfig.json— extends the main config, addsvitest/globalstypes and includes thetest/tree so the IDE recognizesdescribe/it/expectin testsTests
Tests live under
test/and are executed by Vitest in a Node environment (no browser). The configuration is invitest.config.mts.Contributing
License
See the LICENSE file for license rights and limitations (MIT).