@react-email/render 1.0.3 → 1.0.4
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/dist/index.d.mts +23 -0
- package/dist/index.d.ts +23 -0
- package/dist/index.js +768 -0
- package/dist/index.mjs +733 -0
- package/package.json +2 -2
package/dist/index.d.mts
ADDED
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { HtmlToTextOptions } from 'html-to-text';
|
|
2
|
+
import { Options as Options$1 } from 'prettier';
|
|
3
|
+
|
|
4
|
+
type Options = {
|
|
5
|
+
pretty?: boolean;
|
|
6
|
+
} & ({
|
|
7
|
+
plainText?: false;
|
|
8
|
+
} | {
|
|
9
|
+
plainText?: true;
|
|
10
|
+
/**
|
|
11
|
+
* These are options you can pass down directly to the library we use for
|
|
12
|
+
* converting the rendered email's HTML into plain text.
|
|
13
|
+
*
|
|
14
|
+
* @see https://github.com/html-to-text/node-html-to-text
|
|
15
|
+
*/
|
|
16
|
+
htmlToTextOptions?: HtmlToTextOptions;
|
|
17
|
+
});
|
|
18
|
+
|
|
19
|
+
declare const render: (element: React.ReactElement, options?: Options) => Promise<string>;
|
|
20
|
+
|
|
21
|
+
declare const pretty: (str: string, options?: Options$1) => Promise<string>;
|
|
22
|
+
|
|
23
|
+
export { Options, pretty, render };
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { HtmlToTextOptions } from 'html-to-text';
|
|
2
|
+
import { Options as Options$1 } from 'prettier';
|
|
3
|
+
|
|
4
|
+
type Options = {
|
|
5
|
+
pretty?: boolean;
|
|
6
|
+
} & ({
|
|
7
|
+
plainText?: false;
|
|
8
|
+
} | {
|
|
9
|
+
plainText?: true;
|
|
10
|
+
/**
|
|
11
|
+
* These are options you can pass down directly to the library we use for
|
|
12
|
+
* converting the rendered email's HTML into plain text.
|
|
13
|
+
*
|
|
14
|
+
* @see https://github.com/html-to-text/node-html-to-text
|
|
15
|
+
*/
|
|
16
|
+
htmlToTextOptions?: HtmlToTextOptions;
|
|
17
|
+
});
|
|
18
|
+
|
|
19
|
+
declare const render: (element: React.ReactElement, options?: Options) => Promise<string>;
|
|
20
|
+
|
|
21
|
+
declare const pretty: (str: string, options?: Options$1) => Promise<string>;
|
|
22
|
+
|
|
23
|
+
export { Options, pretty, render };
|