You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Thank you for great library. We use the library in both strict and lax mode depending on how flexible we want to be with the user input. One of the things that repeatly trips users up is they paste the domain with a leading dot having removed the subdomains but accidentally left the dot. Not sure if this is something the librar is meant to accept as valid input under lax.
Current Result: { type: 'INVALID', hostname: '.reflectoring.io', errors: [ { type: 'LABEL_MIN_LENGTH', message: 'Label "" is too short. Label is 0 octets long but should be at least 1.', column: 1 } ] }
Thank you for great library. We use the library in both strict and lax mode depending on how flexible we want to be with the user input. One of the things that repeatly trips users up is they paste the domain with a leading dot having removed the subdomains but accidentally left the dot. Not sure if this is something the librar is meant to accept as valid input under lax.
const parseResult = parseDomain(fromUrl(".reflectoring.io"), { validation: Validation.Lax, }); console.log(parseResult);
Current Result:
{ type: 'INVALID', hostname: '.reflectoring.io', errors: [ { type: 'LABEL_MIN_LENGTH', message: 'Label "" is too short. Label is 0 octets long but should be at least 1.', column: 1 } ] }
Expected Result:
{ type: 'LISTED', hostname: 'reflectoring.io', labels: [ 'reflectoring', 'io' ], icann: { subDomains: [], domain: 'reflectoring', topLevelDomains: [ 'io' ] }, subDomains: [], domain: 'reflectoring', topLevelDomains: [ 'io' ] }
The text was updated successfully, but these errors were encountered: