Репозитоий переименован во frontend, обновлены зависимости, добавлен eslint-config

This commit is contained in:
2025-12-26 11:36:35 +04:00
parent 9ac5f6bd28
commit 53dc2d3092
35 changed files with 4464 additions and 2715 deletions

View File

@@ -1,6 +1,6 @@
# pluralize
Склонение существительных в зависимости от чила
Склонение существительных в зависимости от числа
## Использование

View File

@@ -1,7 +1,7 @@
export const pluralize = (count, words) => {
count = Math.abs(count) % 100;
const count10 = count % 10;
if (count > 10 && count < 20) {
const normalizedCount = Math.abs(count) % 100;
const count10 = normalizedCount % 10;
if (normalizedCount > 10 && normalizedCount < 20) {
return words[2];
}
if (count10 > 1 && count10 < 5) {

View File

@@ -5,7 +5,7 @@
"main": "index.js",
"repository": {
"type": "git",
"url": "https://gitea.optiweb.ru/public/helpers.git"
"url": "https://gitea.optiweb.ru/public/frontend.git"
},
"license": "MIT",
"publishConfig": {