Comparing version 1.0.0 to 2.0.0
{ | ||
"name": "levdist", | ||
"version": "1.0.0", | ||
"version": "2.0.0", | ||
"description": "A minimal algorithm for computing Levenshtein distance in JavaScript.", | ||
"main": "index.js", | ||
"main": "lib/index.js", | ||
"directories": { | ||
"test": "test" | ||
"example": "example" | ||
}, | ||
"scripts": { | ||
"test": "node test/index" | ||
"test": "node example/index" | ||
}, | ||
@@ -21,3 +21,3 @@ "repository": { | ||
"author": "Ionică Bizău <bizauionica@gmail.com>", | ||
"license": "MIT", | ||
"license": "KINDLY", | ||
"bugs": { | ||
@@ -27,2 +27,2 @@ "url": "https://github.com/IonicaBizau/node-levdist/issues" | ||
"homepage": "https://github.com/IonicaBizau/node-levdist" | ||
} | ||
} |
@@ -1,11 +0,24 @@ | ||
# levdist | ||
<!----------------------------------------------------------------------------> | ||
<!-- STOP, LOOK & LISTEN! --> | ||
<!-- ==================== --> | ||
<!-- Do NOT edit this file directly since it's generated from a template --> | ||
<!-- file, using https://github.com/IonicaBizau/node-blah --> | ||
<!-- --> | ||
<!-- If you found a typo in documentation, fix it in the source files --> | ||
<!-- (`lib/*.js`) and make a pull request. --> | ||
<!-- --> | ||
<!-- If you have any other ideas, open an issue. --> | ||
<!-- --> | ||
<!-- Please consider reading the contribution steps (CONTRIBUTING.md). --> | ||
<!-- * * * Thanks! * * * --> | ||
<!----------------------------------------------------------------------------> | ||
# levdist [![Donate now][donate-now]][paypal-donations] | ||
A minimal algorithm for computing Levenshtein distance in JavaScript. | ||
## Installation | ||
Run the following commands to download and install the application: | ||
```sh | ||
$ git clone git@github.com:IonicaBizau/node-levdist.git levdist | ||
$ cd levdist | ||
$ npm install | ||
$ npm i levdist | ||
``` | ||
@@ -16,18 +29,35 @@ | ||
```js | ||
// Dependencies | ||
var LevDist = require("levdist"); | ||
// Output the levdist of these two words | ||
console.log(LevDist("live", "life")); | ||
// => 1 | ||
``` | ||
## Documentation | ||
### `LevDist(s, t)` | ||
Calculates the Levenshtein distance. | ||
#### Params | ||
- **String** `s`: The first string. | ||
- **String** `t`: The second string. | ||
#### Return | ||
- **Number** The Levenshtein distance value. | ||
## How to contribute | ||
Have an idea? Found a bug? See [how to contribute][contributing]. | ||
1. File an issue in the repository, using the bug tracker, describing the | ||
contribution you'd like to make. This will help us to get you started on the | ||
right foot. | ||
2. Fork the project in your account and create a new branch: | ||
`your-great-feature`. | ||
3. Commit your changes in that branch. | ||
4. Open a pull request, and reference the initial issue in the pull request | ||
message. | ||
## License | ||
[KINDLY][license] © [Ionică Bizău][website]–The [LICENSE](/LICENSE) file contains | ||
a copy of the license. | ||
## License | ||
See the [LICENSE](./LICENSE) file. | ||
[license]: http://ionicabizau.github.io/kindly-license/?author=Ionic%C4%83%20Biz%C4%83u%20%3Cbizauionica@gmail.com%3E&year=2015 | ||
[contributing]: /CONTRIBUTING.md | ||
[website]: http://ionicabizau.net | ||
[docs]: /DOCUMENTATION.md | ||
[paypal-donations]: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=MG98D7NPFZ3MG | ||
[donate-now]: http://i.imgur.com/jioicaN.png |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Misc. License Issues
License(Experimental) A package's licensing information has fine-grained problems.
Found 1 instance in 1 package
Unidentified License
License(Experimental) Something that seems like a license was found, but its contents could not be matched with a known license.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
8397
7
63
63
1
1
80