1
0
mirror of https://github.com/simple-icons/simple-icons.git synced 2025-07-12 22:21:23 +02:00

Forbid the usage of non secure URLs (#7855)

* Forbid the usage of non secure URLs

* Document in CONTRIBUTING

* Add test to forbid HTTP URLs in documentation pages
This commit is contained in:
Álvaro Mondéjar
2022-09-24 17:37:03 +02:00
committed by GitHub
parent ad7de0434e
commit 3ee620b9d6
7 changed files with 112 additions and 81 deletions

View File

@ -28,6 +28,8 @@ const TITLE_TO_SLUG_CHARS_REGEX = RegExp(
const TITLE_TO_SLUG_RANGE_REGEX = /[^a-z0-9]/g;
export const URL_REGEX = /^https:\/\/[^\s]+$/;
/**
* Get the slug/filename for an icon.
* @param {Object} icon The icon data as it appears in _data/simple-icons.json