parse-domain 8.3.3 → 8.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +18 -0
- package/package.json +3 -2
- package/serialized-tries/info.json +1 -1
package/README.md
CHANGED
|
@@ -44,10 +44,28 @@ The list of top-level domains is stored in a [trie](https://en.wikipedia.org/wik
|
|
|
44
44
|
npm install parse-domain
|
|
45
45
|
```
|
|
46
46
|
|
|
47
|
+
This package is also published to [JSR](https://jsr.io/@peerigon/parse-domain):
|
|
48
|
+
|
|
49
|
+
```sh
|
|
50
|
+
deno add jsr:@peerigon/parse-domain
|
|
51
|
+
```
|
|
52
|
+
|
|
47
53
|
## Updates
|
|
48
54
|
|
|
49
55
|
💡 **Please note:** [publicsuffix.org](https://publicsuffix.org/) is updated several times per month. This package comes with a prebuilt list that has been downloaded at the time of `npm publish`. In order to get an up-to-date list, you should run `npx parse-domain-update` everytime you start or build your application. This will download the latest list from `https://publicsuffix.org/list/public_suffix_list.dat`.
|
|
50
56
|
|
|
57
|
+
JSR packages don't support npm-style `bin` entries, so the script is published under the `./update` export instead. The script writes to a path relative to its own location, so it only works once the package has been resolved into a local `node_modules` directory (e.g. by enabling [`nodeModulesDir`](https://docs.deno.com/runtime/fundamentals/configuration/#node-modules-dir) in `deno.json`) — running it directly off a `jsr:` specifier fails because Deno doesn't expose a local path for remote-cached modules:
|
|
58
|
+
|
|
59
|
+
```jsonc
|
|
60
|
+
// deno.json
|
|
61
|
+
{ "nodeModulesDir": "auto" }
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
```sh
|
|
65
|
+
deno add jsr:@peerigon/parse-domain
|
|
66
|
+
deno run --allow-net --allow-write ./node_modules/@peerigon/parse-domain/src/bin/update.ts
|
|
67
|
+
```
|
|
68
|
+
|
|
51
69
|
<br />
|
|
52
70
|
|
|
53
71
|
## Expected input
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "parse-domain",
|
|
3
|
-
"version": "8.
|
|
3
|
+
"version": "8.4.0",
|
|
4
4
|
"description": "Splits a hostname into subdomains, domain and (effective) top-level domains",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"domain",
|
|
@@ -35,7 +35,8 @@
|
|
|
35
35
|
"main": "./dist/main.js",
|
|
36
36
|
"types": "./dist/main.d.ts",
|
|
37
37
|
"exports": {
|
|
38
|
-
".": "./dist/main.js"
|
|
38
|
+
".": "./dist/main.js",
|
|
39
|
+
"./update": "./dist/bin/update.js"
|
|
39
40
|
},
|
|
40
41
|
"publishConfig": {
|
|
41
42
|
"access": "public",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"updatedAt":"2026-08-
|
|
1
|
+
{"updatedAt":"2026-08-12T11:56:33.471Z"}
|