Package detail

abbrev

npm131.5mISC3.0.1

Like ruby's abbrev module, but in js

readme

abbrev-js

Just like ruby's Abbrev.

Usage:

var abbrev = require("abbrev");
abbrev("foo", "fool", "folding", "flop");

// returns:
{ fl: 'flop'
, flo: 'flop'
, flop: 'flop'
, fol: 'folding'
, fold: 'folding'
, foldi: 'folding'
, foldin: 'folding'
, folding: 'folding'
, foo: 'foo'
, fool: 'fool'
}

This is handy for command-line scripts, or other cases where you want to be able to accept shorthands.

changelog

Changelog

3.0.1 (2025-04-10)

Bug Fixes

  • 1fcc7c9 #100 abbrev works with a single string input (#100) (@owlstronaut)

    Chores

  • 7d26b01 #99 bump @npmcli/template-oss from 4.23.3 to 4.24.3 (#99) (@dependabot[bot], @npm-cli-bot)

3.0.0 (2024-09-24)

⚠️ BREAKING CHANGES

  • abbrev now supports node ^18.17.0 || >=20.5.0

    Bug Fixes

  • e2c25c1 #92 align to npm 10 node engine range (@hashtagchris)

    Chores

  • 9d4e497 #97 enable auto publish (#97) (@reggi)
  • b4c7e46 #93 bump @npmcli/eslint-config from 4.0.5 to 5.0.0 (@dependabot[bot])
  • faa9bf1 #92 run template-oss-apply (@hashtagchris)
  • ff93548 #80 bump @npmcli/template-oss to 4.22.0 (@lukekarrys)
  • 2369d5d #95 postinstall for dependabot template-oss PR (@hashtagchris)
  • 090138a #95 bump @npmcli/template-oss from 4.22.0 to 4.23.3 (@dependabot[bot])

2.0.0 (2022-10-31)

⚠️ BREAKING CHANGES

  • Refactored with the following breaking changes:
    • abbrev is now compatible with the following semver range for node: ^14.17.0 || ^16.13.0 || >=18.0.0
    • monkeyPatch API has been removed

Features

  • 602c0fe add @npmcli/template-oss (#36) (@lukekarrys)

Bug Fixes

  • b658525 replace deprecated String.prototype.substr() (#38) (@CommanderRoot)