Added profile scraper tests (WIP), fixed some profile scrapers. Fixed slugify not breaking existing slugs.

This commit is contained in:
DebaucheryLibrarian
2026-01-10 02:58:50 +01:00
parent 5acc2c607b
commit bddc33a734
12 changed files with 293 additions and 111 deletions

View File

@@ -42,7 +42,7 @@ const accentMap = {
};
const plainCharRegex = /[a-zA-Z0-9]/;
const defaultPunctuationRegex = /[.,?!:;&'"“”…()[]{}<>\/*—-]/;
const defaultPunctuationRegex = /[.,?!:;&'"“”…()[]{}<>\/*—]/;
const defaultSymbolRegex = /[@$€£#%^+=\\~]/;
function slugify(strings, delimiter = '-', {
@@ -66,6 +66,7 @@ function slugify(strings, delimiter = '-', {
: string;
const normalized = casedString
.replace(/[_-]/g, ' ')
.split('')
.map((char) => {
if (char === ' ') {