lexorank
A reference implementation of a list ordering system like JIRA's Lexorank algorithm

lexorank downloads lexorank version lexorank license

lexorankSimilar Packages:
Npm Package Weekly Downloads Trend
3 Years
🌟 Show real-time usage chart on lexorank's README.md, just copy the code below.
## Usage Trend
[![Usage Trend of lexorank](https://npm-compare.com/img/npm-trend/THREE_YEARS/lexorank.png)](https://npm-compare.com/lexorank#timeRange=THREE_YEARS)
Cumulative GitHub Star Trend
🌟 Show GitHub stars trend chart on lexorank's README.md, just copy the code below.
## GitHub Stars Trend
[![GitHub Stars Trend of lexorank](https://npm-compare.com/img/github-trend/lexorank.png)](https://npm-compare.com/lexorank)
Stat Detail
Package
Downloads
Stars
Size
Issues
Publish
License
lexorank74,60222845.1 kB14-MIT
README for lexorank

LexoRank on Typescript

A reference implementation of a list ordering system like JIRA's Lexorank algorithm.

npm version

Getting Started

Npm

npm install lexorank

Yarn

yarn add lexorank

Storyboard

See examples

Using

Static methods

import {LexoRank} from "lexorank";

// min
const minLexoRank = LexoRank.min();
// max
const maxLexoRank = LexoRank.max();
// middle
const middleLexoRank = LexoRank.middle();
// parse
const parsedLexoRank = LexoRank.parse('0|0i0000:');

Public methods

import {LexoRank} from "lexorank";

// any lexoRank
const lexoRank = LexoRank.middle();

// generate next lexorank
const nextLexoRank = lexoRank.genNext();

// generate previous lexorank
const prevLexoRank = lexoRank.genPrev();

// toString
const lexoRankStr = lexoRank.toString();

Calculate LexoRank

LexRank calculation based on existing LexoRanks.

import {LexoRank} from "lexorank";

// any lexorank
const any1LexoRank = LexoRank.min();
// another lexorank
const any2LexoRank = any1LexoRank.genNext().genNext();
// calculate between
const betweenLexoRank = any1LexoRank.between(any2LexoRank);

Related projects

Licence

MIT


I have not found information about the license of the algorithm LexoRank. If the rights are violated, please contact me to correct the current license.