|
Last change
on this file since ba17441 was a762898, checked in by istevanoska <ilinastevanoska@…>, 5 months ago |
|
Added visualizations
|
-
Property mode
set to
100644
|
|
File size:
251 bytes
|
| Line | |
|---|
| 1 | const CASE_SPLIT_PATTERN = /\p{Lu}?\p{Ll}+|[0-9]+|\p{Lu}+(?!\p{Ll})|\p{Emoji_Presentation}|\p{Extended_Pictographic}|\p{L}+/gu;
|
|---|
| 2 | function words(str) {
|
|---|
| 3 | return Array.from(str.match(CASE_SPLIT_PATTERN) ?? []);
|
|---|
| 4 | }
|
|---|
| 5 |
|
|---|
| 6 | export { CASE_SPLIT_PATTERN, words };
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.