diff --git a/.github/maintainers_guide.md b/.github/maintainers_guide.md index 2cb44fd94..a9b5bffc3 100644 --- a/.github/maintainers_guide.md +++ b/.github/maintainers_guide.md @@ -41,7 +41,7 @@ Releasing can feel intimidating at first, but rest assured: if you make a mistak 3. Bump the version number in adherence to [Semantic Versioning](http://semver.org/) in `package.json`. (see [Versioning and Tags](https://github.com/slackapi/node-slack-sdk/blob/main/.github/maintainers_guide.md#versioning-and-tags)) - The version must be in the format of `Major.Minor.Patch-BetaNamespace.BetaVersion` (ex: `5.10.0-workflowStepsBeta.1`, `2.5.0-rc.1`) - - Update any dependency versions in `package.json` and install locally `rm -rf node_modules && npm install` + - Update any dependency versions in `package.json` and install locally `rm -rf node_modules && npm install --include=optional` - Confirm tests pass and code is free of linting errors by running `npm test`. - Make a single commit with a message for the version bump ([Example](https://github.com/slackapi/bolt-js/pull/1133/commits/bcc421cd05b50ddcdeb806fcb27a38d7d9f8ede8)). - Create a pull request for the version change ([Example](https://github.com/slackapi/bolt-js/pull/1133)) diff --git a/.github/workflows/ci-build.yml b/.github/workflows/ci-build.yml index 380685651..b1a4d1245 100644 --- a/.github/workflows/ci-build.yml +++ b/.github/workflows/ci-build.yml @@ -24,7 +24,7 @@ jobs: uses: actions/setup-node@v4 with: node-version: ${{ matrix.node-version }} - - run: npm install + - run: npm install --include=optional - run: npm test - name: Upload coverage to Codecov if: matrix.node-version == '22.x' diff --git a/package.json b/package.json index c58812793..ac94f2d49 100644 --- a/package.json +++ b/package.json @@ -48,7 +48,6 @@ "@slack/types": "^2.13.0", "@slack/web-api": "^7.8.0", "axios": "^1.7.8", - "express": "^5.0.0", "path-to-regexp": "^8.1.0", "raw-body": "^3", "tsscmp": "^1.0.6" @@ -57,7 +56,6 @@ "@biomejs/biome": "^1.9.0", "@tsconfig/node18": "^18.2.4", "@types/chai": "^4.1.7", - "@types/express": "^5.0.0", "@types/mocha": "^10.0.1", "@types/node": "22.10.7", "@types/sinon": "^7.0.11", @@ -72,5 +70,21 @@ "ts-node": "^10.9.2", "tsd": "^0.31.2", "typescript": "5.3.3" + }, + "peerDependencies": { + "express": "^5.0.0", + "@types/express": "^5.0.0", + "@types/express-serve-static-core": "^5.0.0" + }, + "peerDependenciesMeta": { + "express": { + "optional": true + }, + "@types/express": { + "optional": true + }, + "@types/express-serve-static-core": { + "optional": true + } } }