From c08911fdae9cd32f873731e7fb3cfabcc6d40d2d Mon Sep 17 00:00:00 2001 From: ST-DDT Date: Wed, 11 Oct 2023 00:05:37 +0200 Subject: [PATCH] infra(unicorn): escape-case --- .eslintrc.js | 1 - src/modules/git/index.ts | 2 +- src/modules/helpers/index.ts | 2 +- src/modules/internet/index.ts | 2 +- 4 files changed, 3 insertions(+), 4 deletions(-) diff --git a/.eslintrc.js b/.eslintrc.js index e137be56299..0e6d4211d9d 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -51,7 +51,6 @@ module.exports = defineConfig({ 'unicorn/catch-error-name': 'off', 'unicorn/consistent-destructuring': 'off', 'unicorn/consistent-function-scoping': 'off', - 'unicorn/escape-case': 'off', 'unicorn/filename-case': 'off', 'unicorn/import-style': 'off', 'unicorn/no-array-callback-reference': 'off', diff --git a/src/modules/git/index.ts b/src/modules/git/index.ts index ec73c149cea..cbbeb3518e7 100644 --- a/src/modules/git/index.ts +++ b/src/modules/git/index.ts @@ -2,7 +2,7 @@ import type { Faker } from '../..'; import { bindThisToMemberFunctions } from '../../internal/bind-this-to-member-functions'; import { deprecated } from '../../internal/deprecated'; -const nbsp = '\u00a0'; +const nbsp = '\u00A0'; /** * Module to generate git related entries. diff --git a/src/modules/helpers/index.ts b/src/modules/helpers/index.ts index 59a4041a065..b8b63694456 100644 --- a/src/modules/helpers/index.ts +++ b/src/modules/helpers/index.ts @@ -190,7 +190,7 @@ export class SimpleHelpersModule { slugify(string: string = ''): string { return string .normalize('NFKD') //for example è decomposes to as e + ̀ - .replace(/[\u0300-\u036f]/g, '') // removes combining marks + .replace(/[\u0300-\u036F]/g, '') // removes combining marks .replace(/ /g, '-') // replaces spaces with hyphens .replace(/[^\w.-]+/g, ''); // removes all non-word characters except for dots and hyphens } diff --git a/src/modules/internet/index.ts b/src/modules/internet/index.ts index 6e8f822f22f..b6d3e7c1ef3 100644 --- a/src/modules/internet/index.ts +++ b/src/modules/internet/index.ts @@ -636,7 +636,7 @@ export class InternetModule { // First remove simple accents etc result = result .normalize('NFKD') //for example è decomposes to as e + ̀ - .replace(/[\u0300-\u036f]/g, ''); // removes combining marks + .replace(/[\u0300-\u036F]/g, ''); // removes combining marks result = result .split('')