Releases: remusao/tldts
Releases · remusao/tldts
v5.0.3
v5.0.2
v5.0.1
v5.0.0
- Performance improvements in all methods of public API (up to x2 faster)
extractHostname
: will now avoid lower-casing the result in some casesextractHostname
: handles single or triple '/' after protocolextractHostname
: has fast-path for validation of common protocols (e.g. https)isProbablyIpv4
: performs first quick check on length of hostnameisProbablyIpv6
: performs first quick check on length of hostnameisValidHostname
: make use ofcharCodeAt
instead ofcodePointAt
lookupInTrie
: makes use of Trie with more stable structure (faster)lookupInTrie
: lazily allocate memory for resultsuffixLookup
: uses fast-path for most common suffixes (massive speed-up)suffixLookup
: does not allocate memory for result anymoresetDefaults
: fast-path in case no argument was providedgetSubdomain
: fast-path if subdomain is empty
- Add more options to fine-tune behavior and performance
detectIp
allows to disable IP checkmixedInput
allows to specify if we expect a mix of URLs and hostnames as
input. If only hostnames are expected thenextractHostname
can be set to
false
to speed-up parsing. If only URLs are expected thenmixedInputs
can be set tofalse
. ThemixedInputs
is only a hint and will not
change the behavior of the library.validateHostname
can be set tofalse
to disable validation and
speed-up processing further.
- Check that input is string before parsing
- Fix support for reserved keywords in hostnames
- Add tests and bring back coverage to 100%
- Minified bundle is now also tested with the same suite
- Migrate utils scripts from
bin/
folder to TypeScript - Add small
tldts
cli which can be used to parse URLs - Update README with more accurate information