Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -407,11 +407,15 @@ It was a good way to learn more about Github Actions

This action is just an HTTPS POST to Slack API, so you can easily build this by yourself, or use this, or use any other action available on the marketplace :)

## v2 → v3: CommonJS vs ES Modules

The source code moved from CommonJS (`require`) to ES Modules (`import`/`export`) in v3, with `"type": "module"` in `package.json`. However, the bundled action entry point (`dist/index.cjs`) is still built as CommonJS using esbuild. This is intentional for now,`@actions/core` and its dependencies (e.g. `tunnel`) use dynamic `require()` calls for Node built-ins like `net` and `tls`, which fail at runtime inside an ESM bundle. Building the action as CJS avoids this.

## Development and testing

See package.json for `yarn lint`, `yarn test`, etc.

Remember to create the dist with `yarn build`.
Remember to create the dist with `npm run build`.

To run local integration test (from this repository):

Expand Down
2 changes: 1 addition & 1 deletion action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,4 +79,4 @@ outputs:
description: "The result from the post to slack"
runs:
using: "node24"
main: "dist/index.js"
main: "dist/index.cjs"
Loading
Loading