quasiurl 1.1.5 → 1.1.7

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.
Files changed (2) hide show
  1. package/README.md +9 -5
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -4,21 +4,25 @@
4
4
 
5
5
  [![npm](https://img.shields.io/npm/v/quasiurl?labelColor=345&color=46e)](https://www.npmjs.com/package/quasiurl) ![Lightweight](https://img.shields.io/bundlephobia/minzip/quasiurl?label=minzip&labelColor=345&color=46e)
6
6
 
7
+ Installation: `npm i quasiurl`
8
+
7
9
  Unlike `URL`, `QuasiURL`:
8
10
  - can have an empty `origin`, `pathname`, `hostname`, `protocol`;
9
11
  - preserves templating characters without URL-encoding them;
10
12
  - doesn't implement the entire `URL` spec.
11
13
 
12
- ```
14
+ ```js
15
+ import { QuasiURL } from "quasiurl";
16
+
13
17
  new URL("/x").href
14
- > TypeError: URL constructor: /x is not a valid URL.
18
+ // TypeError: URL constructor: /x is not a valid URL.
15
19
 
16
20
  new QuasiURL("/x").href
17
- > "/x"
21
+ // "/x"
18
22
 
19
23
  new URL("https://a.aa/x{/:name}").pathname
20
- > "/x%7B/:name%7D"
24
+ // "/x%7B/:name%7D"
21
25
 
22
26
  new QuasiURL("https://a.aa/x{/:name}").pathname
23
- > "/x{/:name}"
27
+ // "/x{/:name}"
24
28
  ```
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "quasiurl",
3
- "version": "1.1.5",
3
+ "version": "1.1.7",
4
4
  "description": "URL for templating",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",