type-is is a Node.js module that infers or checks the content-type of an HTTP request. It provides helpers to detect the request content-type against a list of media types, handle wildcards and suffixes, and determine whether a request has a body even when the Content-Type header is missing or invalid.
Project status
- Actively maintained: The upstream repo has recent activity (last push on 2026-09-21) and published updates as recently as 2026-09-21 (v3.0.0), indicating ongoing maintenance rather than a quiet period.
- Update cadence: After updates in 2025-03, the project shows a re-accelerated cadence in 2026, with an update in 2026-05 (v2.1.0) followed by another in 2026-09 (v3.0.0), suggesting releases are happening on a timescale of a few months rather than years.
AI summary generated
Recent updates
v3.0.0
v3.0.0 is a major rewrite that switches the package to ESM and requires Node.js 22+. The public API is refactored from the old CommonJS function-based interface to a reusable TypeIs class, with improved MIME matching behavior including parameter support and returning the originally provided matcher token.
BreakingFeaturesv2.1.0
v2.1.0 upgrades the content-type dependency to v2 and refactors how this package normalizes MIME types for faster parsing. In addition to library changes, the release also updates CI workflows (CI permissions, CodeQL workflow) and bumps some GitHub Action versions.
BreakingFeatures2.0.1
Version 2.0.1 is a small refactor release focused on internal code cleanup and minor logic simplifications. It updates a few string handling operations (replacing deprecated String.prototype.substr usage) and slightly streamlines argument normalization in typeofrequest.
2.0.0
Release 2.0.0 primarily updates project tooling and documentation, adding a GitHub Actions CI workflow and an OSSF Scorecard supply-chain security workflow. The release notes themselves do not describe any runtime behavior changes. However, the code diff shows a significant change to how media types are parsed and normalized, alongside dependency upgrades.
SecurityFeatures1.6.18
Release 1.6.18 is a small patch release for the `type-is` package. The only described change is a fix for a regression related to how request objects were handled when calling `typeis.is`. The diff also shows expanded README and a significantly larger test suite for `typeis.is`.
1.6.17
Release 1.6.17 primarily updates the runtime dependency mime-types to a newer IANA-based mapping and adjusts documentation/badges. It also introduces a small runtime guard to avoid internal exceptions when an invalid (non-string) type value is provided.
1.6.16
Release 1.6.16 primarily bumps the runtime dependency mime-types from ~2.1.15 to ~2.1.18. The published release notes document the new and updated MIME type mappings introduced by that mime-types update.
1.6.15
Release 1.6.15 primarily updates the mime-types dependency (adding new MIME type mappings). The rest of the diff is tooling and documentation related, including CI (Travis) matrix tweaks and modernized linting setup.
Features1.6.14
This release updates the type-is package dependencies and CI/test tooling. The release notes only call out a mime-types bump, but the diff also modifies Travis CI Node.js versions, the lint script, and a dev dependency version.
1.6.13
Release 1.6.13 primarily bumps the mime-types dependency to ~2.1.11. The bundled library code changes shown in the diff are largely formatting/linting related, while the repo also adds ESLint configuration and updates CI/dev tooling.
1.6.12
Release 1.6.12 updates the mime-types dependency (from ~2.1.9 to ~2.1.10) and includes the resulting mime type metadata changes described in the release notes. The only other code diff content is documentation text and changelog metadata updates, with no functional runtime code changes shown.
Features