ghtml 3.0.1 → 3.0.2
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/package.json +1 -1
- package/src/html.d.ts +6 -6
- package/src/html.js +3 -3
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"description": "Replace your template engine with fast JavaScript by leveraging the power of tagged templates.",
|
|
4
4
|
"author": "Gürgün Dayıoğlu",
|
|
5
5
|
"license": "MIT",
|
|
6
|
-
"version": "3.0.
|
|
6
|
+
"version": "3.0.2",
|
|
7
7
|
"type": "module",
|
|
8
8
|
"bin": "./bin/src/index.js",
|
|
9
9
|
"main": "./src/index.js",
|
package/src/html.d.ts
CHANGED
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @param {{ raw: string[] }} literals Tagged template literals.
|
|
2
|
+
* @param {{ raw: Readonly<string[]> }} literals Tagged template literals.
|
|
3
3
|
* @param {...any} expressions Expressions to interpolate.
|
|
4
4
|
* @returns {string} The HTML string.
|
|
5
5
|
*/
|
|
6
6
|
export function html({ raw: literals }: {
|
|
7
|
-
raw: string[]
|
|
7
|
+
raw: Readonly<string[]>;
|
|
8
8
|
}, ...expressions: any[]): string;
|
|
9
9
|
/**
|
|
10
|
-
* @param {{ raw: string[] }} literals Tagged template literals.
|
|
10
|
+
* @param {{ raw: Readonly<string[]> }} literals Tagged template literals.
|
|
11
11
|
* @param {...any} expressions Expressions to interpolate.
|
|
12
12
|
* @yields {string} The HTML strings.
|
|
13
13
|
*/
|
|
14
14
|
export function htmlGenerator({ raw: literals }: {
|
|
15
|
-
raw: string[]
|
|
15
|
+
raw: Readonly<string[]>;
|
|
16
16
|
}, ...expressions: any[]): {};
|
|
17
17
|
/**
|
|
18
|
-
* @param {{ raw: string[] }} literals Tagged template literals.
|
|
18
|
+
* @param {{ raw: Readonly<string[]> }} literals Tagged template literals.
|
|
19
19
|
* @param {...any} expressions Expressions to interpolate.
|
|
20
20
|
* @yields {string} The HTML strings.
|
|
21
21
|
*/
|
|
22
22
|
export function htmlAsyncGenerator({ raw: literals }: {
|
|
23
|
-
raw: string[]
|
|
23
|
+
raw: Readonly<string[]>;
|
|
24
24
|
}, ...expressions: any[]): {};
|
package/src/html.js
CHANGED
|
@@ -39,7 +39,7 @@ const escapeFunction = (string) => {
|
|
|
39
39
|
};
|
|
40
40
|
|
|
41
41
|
/**
|
|
42
|
-
* @param {{ raw: string[] }} literals Tagged template literals.
|
|
42
|
+
* @param {{ raw: Readonly<string[]> }} literals Tagged template literals.
|
|
43
43
|
* @param {...any} expressions Expressions to interpolate.
|
|
44
44
|
* @returns {string} The HTML string.
|
|
45
45
|
*/
|
|
@@ -72,7 +72,7 @@ const html = ({ raw: literals }, ...expressions) => {
|
|
|
72
72
|
};
|
|
73
73
|
|
|
74
74
|
/**
|
|
75
|
-
* @param {{ raw: string[] }} literals Tagged template literals.
|
|
75
|
+
* @param {{ raw: Readonly<string[]> }} literals Tagged template literals.
|
|
76
76
|
* @param {...any} expressions Expressions to interpolate.
|
|
77
77
|
* @yields {string} The HTML strings.
|
|
78
78
|
*/
|
|
@@ -166,7 +166,7 @@ const htmlGenerator = function* ({ raw: literals }, ...expressions) {
|
|
|
166
166
|
};
|
|
167
167
|
|
|
168
168
|
/**
|
|
169
|
-
* @param {{ raw: string[] }} literals Tagged template literals.
|
|
169
|
+
* @param {{ raw: Readonly<string[]> }} literals Tagged template literals.
|
|
170
170
|
* @param {...any} expressions Expressions to interpolate.
|
|
171
171
|
* @yields {string} The HTML strings.
|
|
172
172
|
*/
|