|
1 | | -<!-- Copyright (C) 2025 Subhajit Sahu --> |
2 | | -<!-- SPDX-License-Identifier: AGPL-3.0-or-later --> |
3 | | -<!-- See LICENSE for full terms --> |
4 | | - |
5 | | -A [string] is a sequence of characters. In JavaScript, strings are not [mutable]. Any transfomation of a *string*, such as `slice` or `concat` generates a *new string*. The *JavaScript runtime* however may optimize this behavior by *mutating strings behind the scenes*, when it can be guarenteed that the previous string is *not accessible* to the programmer. The *runtime* may also *avoid copying slices* of a string, or even *concatenation of slices of* *strings*, by implementing it as a *series of lookups into existing strings*. Food for thought. |
6 | | - |
7 | | -This package provides **functions** for generating spaces, querying *about* a string, *comparing* strings, getting *parts* of a string, *searching* a string, *transforming* a string or its *case*, finding *ngrams* in strings, finding *similarity/distance* between strings, and array-like functions. All **built-in** string functions are also included. Finally, *constants* for *ASCII characters*, and *minimum/maximum code point* are included. |
| 1 | +A [string] is a sequence of characters. |
8 | 2 |
|
9 | 3 | ▌ |
10 | 4 | 📦 [JSR](https://jsr.io/@nodef/extra-string), |
| 5 | +📦 [NPM](https://www.npmjs.com/package/extra-string), |
11 | 6 | 📰 [Docs](https://jsr.io/@nodef/extra-string/doc). |
12 | 7 |
|
| 8 | +In JavaScript, strings are not [mutable]. Any transfomation of a *string*, such as `slice` or `concat` generates a *new string*. The *JavaScript runtime* however may optimize this behavior by *mutating strings behind the scenes*, when it can be guarenteed that the previous string is *not accessible* to the programmer. The *runtime* may also *avoid copying slices* of a string, or even *concatenation of slices of* *strings*, by implementing it as a *series of lookups into existing strings*. Food for thought. |
| 9 | + |
| 10 | +This package provides **functions** for generating spaces, querying *about* a string, *comparing* strings, getting *parts* of a string, *searching* a string, *transforming* a string or its *case*, finding *ngrams* in strings, finding *similarity/distance* between strings, and array-like functions. All **built-in** string functions are also included. Finally, *constants* for *ASCII characters*, and *minimum/maximum code point* are included. |
| 11 | + |
13 | 12 | [string]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String |
14 | 13 | [mutable]: https://developer.mozilla.org/en-US/docs/Glossary/Mutable |
15 | | -[jsDelivr CDN]: https://cdn.jsdelivr.net/npm/extra-string.web/index.js |
16 | 14 |
|
17 | 15 | <br> |
18 | 16 |
|
@@ -190,14 +188,6 @@ xstring.tverskyDistance('pikachu', 'raichu', 3, 0.2, 0.4); |
190 | 188 | <br> |
191 | 189 |
|
192 | 190 |
|
193 | | -## License |
194 | | - |
195 | | -As of 26 June 2025, this project is licensed under AGPL-3.0. Previous versions remain under MIT. |
196 | | - |
197 | | -<br> |
198 | | -<br> |
199 | | - |
200 | | - |
201 | 191 | [](https://wolfram77.github.io)<br> |
202 | 192 | [](https://nodef.github.io) |
203 | 193 |  |
|
0 commit comments