Skip to content

Improve stripWWW logic#117

Merged
sindresorhus merged 3 commits intosindresorhus:masterfrom
Tundaware:116-fix-strip-www-regex
Aug 2, 2020
Merged

Improve stripWWW logic#117
sindresorhus merged 3 commits intosindresorhus:masterfrom
Tundaware:116-fix-strip-www-regex

Conversation

@gcox
Copy link
Copy Markdown
Contributor

@gcox gcox commented Jul 31, 2020

Fixes #116

* Supports TLDs up to 63 characters like other DNS labels. There are existing TLDs that are at least 25 characters long.
* Supports single character domains
* Supports internationalized TLDs (requires allowing for "-" and numeric characters in the TLD): https://en.wikipedia.org/wiki/List_of_Internet_top-level_domains#Internationalized_country_code_top-level_domains
Comment thread test.js Outdated
@sindresorhus sindresorhus changed the title Improves stripWWW related regex Improve stripWWW feature Aug 2, 2020
@sindresorhus sindresorhus changed the title Improve stripWWW feature Improve stripWWW logic Aug 2, 2020
@sindresorhus sindresorhus merged commit 0ee9d94 into sindresorhus:master Aug 2, 2020
@sindresorhus
Copy link
Copy Markdown
Owner

Thanks ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Strip WWW doesn't work on some domains

2 participants