Skip to content

Releases: slevithan/regex

v6.0.1

31 Jan 17:23
Compare
Choose a tag to compare
  • ./internals: Update plugin argument types.

v6.0.0

29 Jan 18:54
Compare
Choose a tag to compare

This version's breaking changes don't alter direct use of the library, so they won't affect most users. The modified APIs are used by tools that build on top of Regex+.

🚨 Breaking

  • rewrite: Renamed the returned expression property as pattern.
  • Plugins: Returned values are now expected to be an object with string property pattern.
  • Plugins: Hidden capture indices are now explicitly provided/returned, rather than embedded via markers in the pattern.
  • ./internals: Removed RegExpSubclass's undocumented support for capture transfer.
  • ./internals: Removed emulationGroupMarker; markers are no longer used for hidden captures.

🚀 Features

  • Improved performance of the subclass option, especially with long patterns that contain extended syntax.

v5.1.1

26 Dec 23:39
Compare
Choose a tag to compare

🐞 Fixes

  • Edge case fix for emulation-only capturing groups with transfer markers (for libraries that use Regex+ internals).

v5.1.0

26 Dec 20:44
Compare
Choose a tag to compare

🚀 Features

  • Export emulationGroupMarker in ./internals.
  • Add support for emulation groups with capture transfer to RegExpSubclass.
    • Intended for use in libraries that build on Regex+ internals. This feature is undocumented and experimental.

v5.0.2

18 Nov 17:10
Compare
Choose a tag to compare

🚀 Features

  • Enables better tree shaking for ./internals.

v5.0.1

17 Nov 18:06
Compare
Choose a tag to compare

🚀 Features

  • Minor improvements for subclass types and error handling.
  • Updated logo for new library name.

v5.0.0

15 Nov 21:25
Compare
Choose a tag to compare

This library was renamed from just regex to Regex+, to make it easier to refer to the library and its regex flavor. The package and tag name remain regex as before, so this has no effect on code.

Version 5 is a minor update with small breaking changes that won't affect most people.

🚨 Breaking

  • Type files (d.ts) were moved from ./types to ./dist/esm and ./dist/cjs.
  • The undocumented ./atomic export added in v4.4.0 was renamed as ./internals.

🚀 Features

  • RegExpSubclass was made available via ./internals.

🐞 Fixes

  • Type resolution works correctly when using the library as CommonJS. (#29, @tao-cumplido)
  • When using option subclass and flag d, resulting subpattern indices are adjusted to account for emulation groups.

v4.4.0

01 Nov 17:55
Compare
Choose a tag to compare

🚀 Features

  • Added ./atomic to exports, allowing direct use of the atomic and possessive plugins in other libraries.

v4.3.3

02 Oct 15:52
Compare
Choose a tag to compare

🚀 Features

  • When an invalid regex throws, always include the generated source and flags in the error message (some browsers automatically include them, but Firefox and Safari don't).

🐞 Fixes

  • Convert numbers interpolated in enclosed \u{…} to hexadecimal. In other words, although interpolating a string like regex`\u{${'160'}}` returns /\u{160}/, interpolating the number regex`\u{${160}}` in this context returns /\u{A0}/. (#24, @graphemecluster)

v4.3.2

07 Sep 23:36
Compare
Choose a tag to compare

🐞 Fixes

  • Fix for character classes that contain + after certain other punctuation.