NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
pub.dev · #2440 most downloaded on pub.dev
A domain parser based on the Public Suffix List, for identifying the root and suffix/TLD of URLs.
Last release 6 years ago
no release in 18 months
Release timing varies
gaps range from 1 weeks to 1.2 years
Nearly every release is documented
notes for 7 of 7 stable releases
Nothing withdrawn
no release was ever pulled
7 years old
7 releases · first in 2019
Minimum Dart SDK requirement changed to 2.12.0.
Add example/example.md to make the new examples show up on pub.dev.
One column per quarter.
SuffixRules is no longer static.
SuffixRules is no longer static.
DefaultSuffixRules has been added to provide a statically accessible rules list with a similar API to the old SuffixRules.PublicSuffix now takes an optional argument when created to specify the SuffixRules to use. If unspecified, DefaultSuffixRules is used (similar to previous version).SuffixRules.process and SuffixRules.validate to a new class, SuffixRulesParser.PublicSuffix now takes either a String or a URL.PublicSuffix.fromString and fromUrl with adjustable leniency for invalid URLs (fixes #4).
PublicSuffix instances without getting exceptions thrown if the URL is null/empty/invalid. See the documentation for full details.PublicSuffix.sourceUri to PublicSuffix.sourceUrl.public_suffix.dart from the helper files.public_suffix_io.dart and public_suffix_browser.dart to io_helper.dart and browser_helper.dart.END PRIVATE is now respected when loading a suffix list. This means that a list can contain the private section anywhere in the list or even have multiple private sections.SuffixRules.hasRules - checks if at least one rule exists.SuffixRules.fromRules - creates a SuffixRules instance from an existing list of Rule objects.a.*.c).SuffixRules objects (treated as empty lists).Improved the suffix list format documentation in SuffixRules and the SuffixRulesHelper s.
Changes
SuffixRules and the SuffixRulesHelpers.DomainUtils.DomainUtils.isKnownSuffix not throwing if SuffixRules hasn't been initialised.test_coverage dev dependency (doesn't work for browser tests).SuffixRules.Updated docs and parameter names to say URL instead of URI, which is more correct ( PublicSuffix.sourceUri is unchanged to avoid breaking changes).
Additions
ruleMap to SuffixRules to speed up the performance when matching rules.subdomain and icannSubdomain to PublicSuffix.isSubdomainOf, hasKnownSuffix and hasValidDomain to PublicSuffix.DomainUtils with the following static functions:
isSubdomainOfisSubdomainisKnownSuffixhasValidDomainPublicSuffix.fromString as a convenience method for PublicSuffix(Uri.parse(string)).Changes
PublicSuffix.sourceUri is unchanged to avoid breaking changes).Added primary library public_suffix.dart , which can be used without dart:io and dart:html (but still requires to be initialised with a suffix list).
Additions
public_suffix.dart, which can be used without dart:io and dart:html (but still requires to be initialised with a suffix list).Load suffix rule lists from strings or URIs.
This is the first release.
Changelog
co.uk)google)google.co.uk)Your coding agent can read these notes before it upgrades. Set up the MCP server →