Perf: 1-pass domain parse

This commit is contained in:
SukkaW
2024-06-07 10:18:31 +08:00
parent 2eb48289b7
commit fba420ee4c
2 changed files with 10 additions and 13 deletions

View File

@@ -19,7 +19,7 @@ import { getGorhillPublicSuffixPromise } from './get-gorhill-publicsuffix';
mixedInputs: false
};
(['getDomain', 'getPublicSuffix', 'getSubdomain'] as const).forEach(methodName => {
(['getDomain', 'getPublicSuffix', 'getSubdomain', 'parse'] as const).forEach(methodName => {
group(methodName, () => {
if (methodName in gorhill) {
bench('gorhill', () => {