Migrate to esm#290
Merged
Merged
Conversation
- Add 'type: module' to package.json for native ESM - Replace ncc with tsup (esbuild-based bundler with first-class ESM) - Replace Jest/ts-jest with Vitest 3 - Replace ts-node with tsx - Upgrade @actions/artifact from v5 to v6 (pure ESM) - Add .js extensions to all relative imports (NodeNext requirement) - Fix bare directory imports (from '.' → './index.js') - Fix path alias imports to include .js extensions for NodeNext - Replace __dirname with import.meta.dirname in reports/core.ts - Add eslint.config.mjs (ESLint v9 flat config) - Add tsconfig.eslint.json for linting test files with Vitest globals - Update tsconfig.json excludes for new config files - Delete .eslintignore (replaced by ignores in eslint.config.mjs) All 89 tests pass. Full pipeline: format → lint → test → coverage → bundle ✓
Bundle CJS deps (like @actions/core and yargs) need require(), __dirname and __filename to be available in ESM scope. Add a banner that injects these via createRequire and import.meta properties (Node 21.2+).
…fix ESM import hoisting
build-and-test: Run #1536
🎉 All tests passed!Github Test Reporter by CTRF 💚 |
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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.