Skip to content

Conversation

@honzabubenik
Copy link
Contributor

@honzabubenik honzabubenik commented Aug 28, 2025

Summary

This pull request includes multiple changes to improve code quality, update dependencies, and enhance tooling:

  1. Updated ESLint configuration to enforce .js extensions in imports and address path alias issues.
  2. Added a script (node-test-matrix.sh) to test code under multiple Node.js versions (20, 22, and 24), and updated the GitHub Actions workflow (qa.yml) to include this test matrix. Also specified supported Node.js engines (>=20) in package.json.
  3. Refactored imports by using type-only imports where applicable and implemented a new assertNotNull utility.
  4. Fixed code formatting issues with Prettier.
  5. Upgraded development dependencies, including ESLint, Prettier, TypeScript configurations, and other related libraries. Specific additions were also made to package-lock.json, reflecting new optional platform builds.

Changes Made

  • Enforcement of .js extensions and adjustments to ESLint path alias and extension rules.
  • Tooling improvements with Node.js version testing and CI workflow updates.
  • Type-safety optimizations and the addition of assertNotNull.
  • Consistent code formatting through Prettier fixes.
  • Dependency upgrades to ensure alignment with the latest releases and enhancements.

- Update @localazy/eslint-config to ^1.3.0
- Update @localazy/prettier-config to ^1.2.0
- Update @localazy/tsconfig to ^1.1.1
- Update eslint to ^9.34.0
- Update fetch-mock to ^12.5.4
- Update @types/node to ^22.18.0
- Update unplugin-replace to ^0.6.1
- Update vite to ^7.1.3

Includes additions to `package-lock.json` with new optional dependencies and specific platform builds.
- Add `node-test-matrix.sh` to test under Node.js versions 20, 22, and 24.
- Update `qa.yml` GitHub workflow to run jobs across the Node.js version matrix.
- Specify supported Node.js engines (`>=20`) in `package.json`.
…js` extensions in imports

- Upgrade multiple dependencies, such as `vue`, `vitepress`, `sass`, `postcss`, and others for alignment with the latest versions.
- Replace imports with `.js` extensions to support ESM compatibility.
- Adjust `tsconfig.json` to use `ESNext` modules and `bundler` resolution for compatibility with updated dependencies.
- Use type-only imports where applicable.
@github-actions
Copy link

Coverage Report

Status Category Percentage Covered / Total
🔵 Lines 100% 707 / 707
🔵 Statements 100% 707 / 707
🔵 Functions 100% 84 / 84
🔵 Branches 100% 201 / 201
File Coverage
File Stmts Branches Functions Lines Uncovered Lines
Changed Files
src/main.ts 100% 100% 100% 100%
src/cdn/cdn-client.ts 100% 100% 100% 100%
src/cdn/api/api.ts 100% 100% 100% 100%
src/cdn/cache/locales-cache.ts 100% 100% 100% 100%
src/cdn/cache/memory-cache-adapter.ts 100% 100% 100% 100%
src/cdn/context/context.ts 100% 100% 100% 100%
src/cdn/context/metafile-context.ts 100% 100% 100% 100%
src/cdn/http/fetch-http-adapter.ts 100% 100% 100% 100%
src/cdn/metafile/metafile-data.ts 100% 100% 100% 100%
src/cdn/metafile/metafile-file.ts 100% 100% 100% 100%
src/cdn/metafile/metafile-locale.ts 100% 100% 100% 100%
src/cdn/metafile/metafile-params.ts 100% 100% 100% 100%
src/cdn/methods/cdn-base.ts 100% 100% 100% 100%
src/cdn/methods/cdn-cache.ts 100% 100% 100% 100%
src/cdn/methods/cdn-metafile.ts 100% 100% 100% 100%
src/cdn/request/locales-map.ts 100% 100% 100% 100%
src/cdn/request/request-builder.ts 100% 100% 100% 100%
src/cdn/request/request.ts 100% 100% 100% 100%
src/cdn/response/response-factory.ts 100% 100% 100% 100%
src/interfaces/i-locales-cache-item.ts 0% 0% 0% 0%
src/interfaces/i-metafile-file.ts 0% 0% 0% 0%
src/interfaces/i-metafile-files.ts 0% 0% 0% 0%
src/interfaces/i-metafile.ts 0% 0% 0% 0%
src/interfaces/i-request-builder.ts 0% 0% 0% 0%
src/types/api-locale-request.ts 0% 0% 0% 0%
src/types/cache-get-locales-request.ts 0% 0% 0% 0%
src/types/cache-has-locales-request.ts 0% 0% 0% 0%
src/types/cache-key-metafile-options.ts 0% 0% 0% 0%
src/types/cache-store-locales-request.ts 0% 0% 0% 0%
src/types/cdn-fetch-options.ts 0% 0% 0% 0%
src/types/cdn-file.ts 0% 0% 0% 0%
src/types/context-options.ts 0% 0% 0% 0%
src/types/files-map.ts 0% 0% 0% 0%
src/types/locale-response.ts 0% 0% 0% 0%
src/types/locales-map-data.ts 0% 0% 0% 0%
src/types/locales-map-options.ts 0% 0% 0% 0%
src/types/metafile-file-options.ts 0% 0% 0% 0%
src/types/metafile-options.ts 0% 0% 0% 0%
src/types/response-factory-options.ts 0% 0% 0% 0%
Generated in workflow #54 for commit 4691289 by the Vitest Coverage Report Action

@honzabubenik honzabubenik merged commit e661edd into main Aug 28, 2025
7 of 9 checks passed
@honzabubenik honzabubenik deleted the fix_audit branch August 28, 2025 22:23
@localazy-bot localazy-bot bot mentioned this pull request Aug 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants