Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

has-named-captures

inspect-js1.9kMIT1.0.0TypeScript support: included

Does the JS environment support named capture groups in regexes?

javascript, regex, regular-expression, capture, group, regular-expressions, named

readme

has-named-captures Version Badge

github actions coverage License Downloads

npm badge

Does the JS environment support named capture groups in regexes?

Returns true in node 10+, and equivalent engines.

Example

var hasNamedCaptures = require('has-named-captures');
var assert = require('assert');

assert.equal(typeof hasNamedCaptures(), 'boolean', 'returns true or false');

Tests

Simply clone the repo, npm install, and run npm test

changelog

Changelog

All notable changes to this project will be documented in this file.

The format is based on Keep a Changelog and this project adheres to Semantic Versioning.

v1.0.0 - 2024-01-29

Commits