JSPM

alphanum-sort

1.0.2
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 2120734
  • Score
    100M100P100Q213273F
  • License MIT

Alphanumeric sorting algorithm

Package Exports

  • alphanum-sort

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (alphanum-sort) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

alphanum-sort

Build Status

Alphanumeric sorting algorithm

Install

With npm do:

npm i alphanum-sort -S

Example

var sort = require('alphanum-sort');

var result = sort(['item20', 'item19', 'item1', 'item10', 'item2']);
// ['item1', 'item2', 'item10', 'item19', 'item20']

API

alphanumSort(array, options)

options

insensitive

Type: Boolean Default: false

Compares items case insensitively

sign

Type: Boolean Default: false

Allows + and - characters before numbers

License

MIT © Bogdan Chadkin