@maizzle/framework 4.8.7 → 5.0.0-beta.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.
Files changed (80) hide show
  1. package/bin/maizzle +3 -1
  2. package/package.json +65 -58
  3. package/src/commands/build.js +244 -19
  4. package/src/commands/serve.js +2 -197
  5. package/src/generators/plaintext.js +192 -91
  6. package/src/generators/render.js +128 -0
  7. package/src/index.js +46 -14
  8. package/src/{generators/posthtml → posthtml}/defaultComponentsConfig.js +6 -4
  9. package/src/{generators/posthtml → posthtml}/defaultConfig.js +1 -1
  10. package/src/posthtml/index.js +74 -0
  11. package/src/posthtml/plugins/expandLinkTag.js +36 -0
  12. package/src/server/client.js +181 -0
  13. package/src/server/index.js +383 -0
  14. package/src/server/routes/hmr.js +24 -0
  15. package/src/server/routes/index.js +38 -0
  16. package/src/server/views/error.html +83 -0
  17. package/src/server/views/index.html +24 -0
  18. package/src/server/websockets.js +27 -0
  19. package/src/transformers/addAttributes.js +30 -0
  20. package/src/transformers/attributeToStyle.js +30 -36
  21. package/src/transformers/baseUrl.js +52 -23
  22. package/src/transformers/comb.js +51 -0
  23. package/src/transformers/core.js +20 -0
  24. package/src/transformers/filters/defaultFilters.js +90 -70
  25. package/src/transformers/filters/index.js +14 -78
  26. package/src/transformers/index.js +268 -63
  27. package/src/transformers/inline.js +240 -0
  28. package/src/transformers/markdown.js +13 -14
  29. package/src/transformers/minify.js +21 -16
  30. package/src/transformers/posthtmlMso.js +13 -8
  31. package/src/transformers/prettify.js +16 -15
  32. package/src/transformers/preventWidows.js +32 -26
  33. package/src/transformers/removeAttributes.js +17 -17
  34. package/src/transformers/replaceStrings.js +30 -9
  35. package/src/transformers/safeClassNames.js +24 -24
  36. package/src/transformers/shorthandCss.js +22 -0
  37. package/src/transformers/sixHex.js +15 -15
  38. package/src/transformers/urlParameters.js +18 -16
  39. package/src/transformers/useAttributeSizes.js +65 -0
  40. package/src/utils/getConfigByFilePath.js +124 -0
  41. package/src/utils/node.js +68 -0
  42. package/src/utils/string.js +117 -0
  43. package/types/build.d.ts +117 -57
  44. package/types/components.d.ts +130 -112
  45. package/types/config.d.ts +454 -242
  46. package/types/css/inline.d.ts +234 -0
  47. package/types/css/purge.d.ts +125 -0
  48. package/types/events.d.ts +5 -105
  49. package/types/index.d.ts +148 -116
  50. package/types/markdown.d.ts +20 -18
  51. package/types/minify.d.ts +122 -120
  52. package/types/plaintext.d.ts +46 -52
  53. package/types/posthtml.d.ts +103 -136
  54. package/types/render.d.ts +0 -117
  55. package/types/urlParameters.d.ts +21 -20
  56. package/types/widowWords.d.ts +9 -7
  57. package/src/functions/plaintext.js +0 -5
  58. package/src/functions/render.js +0 -5
  59. package/src/generators/config.js +0 -52
  60. package/src/generators/output/index.js +0 -4
  61. package/src/generators/output/to-disk.js +0 -254
  62. package/src/generators/output/to-string.js +0 -73
  63. package/src/generators/postcss.js +0 -23
  64. package/src/generators/posthtml/index.js +0 -75
  65. package/src/generators/tailwindcss.js +0 -157
  66. package/src/transformers/extraAttributes.js +0 -33
  67. package/src/transformers/inlineCss.js +0 -42
  68. package/src/transformers/removeInlineBackgroundColor.js +0 -56
  69. package/src/transformers/removeInlineSizes.js +0 -43
  70. package/src/transformers/removeInlinedSelectors.js +0 -100
  71. package/src/transformers/removeUnusedCss.js +0 -48
  72. package/src/transformers/shorthandInlineCSS.js +0 -26
  73. package/src/utils/helpers.js +0 -13
  74. package/types/baseUrl.d.ts +0 -79
  75. package/types/fetch.d.ts +0 -143
  76. package/types/inlineCss.d.ts +0 -207
  77. package/types/layouts.d.ts +0 -39
  78. package/types/removeUnusedCss.d.ts +0 -115
  79. package/types/tailwind.d.ts +0 -22
  80. package/types/templates.d.ts +0 -181
package/types/index.d.ts CHANGED
@@ -1,90 +1,110 @@
1
- import type {AttributeToStyleSupportedAttributes} from './inlineCss';
2
- import type BaseURLConfig from './baseURL';
3
1
  import type Config from './config';
4
- import type {CoreBeautifyOptions} from 'js-beautify';
5
- import type InlineCSSConfig from './inlineCss';
6
- import type {Options as MarkdownItOptions} from 'markdown-it';
7
2
  import type MinifyConfig from './minify';
3
+ import type PostHTMLConfig from './posthtml';
4
+ import type { RenderOutput } from './render';
5
+ import type MarkdownConfig from './markdown';
6
+ import type PurgeCSSConfig from './css/purge';
8
7
  import type PlaintextConfig from './plaintext';
9
- import type RenderOptions from './render';
10
- import type {RenderOutput} from './render';
11
- import type RemoveUnusedCSSConfig from './removeUnusedCss';
12
- import type URLParametersConfig from './urlParameters';
8
+ import type CSSInlineConfig from './css/inline';
13
9
  import type WidowWordsConfig from './widowWords';
10
+ import type { BaseURLConfig } from 'posthtml-base-url';
11
+ import type { HTMLBeautifyOptions } from 'js-beautify'
12
+ import type { URLParametersConfig } from 'posthtml-url-parameters';
13
+ import type { AttributeToStyleSupportedAttributes } from './css/inline';
14
14
 
15
15
  declare namespace MaizzleFramework {
16
16
  /**
17
- Compile an HTML string with Maizzle.
18
-
19
- @param {string} html The HTML string to render.
20
- @param {RenderOptions} [options] Options to pass to the renderer.
21
- */
22
- function render(html: string, options?: RenderOptions): Promise<RenderOutput>;
17
+ * Compile an HTML string with Maizzle.
18
+ *
19
+ * @param {string} html The HTML string to render.
20
+ * @param {Config} [config] A Maizzle configuration object.
21
+ * @returns {Promise<RenderOutput>} The rendered HTML and the Maizzle configuration object.
22
+ */
23
+ function render(html: string, config?: Config): Promise<RenderOutput>;
23
24
 
24
25
  /**
25
- Normalize escaped character class names like `\:` or `\/` by replacing them with email-safe alternatives.
26
-
27
- @param {string} html The HTML string to render.
28
- @param {object} replacements Customize replacements strategy.
26
+ * Normalize escaped character class names like `\:` or `\/` by replacing them with email-safe alternatives.
27
+ *
28
+ * @param {string} html The HTML string to normalize.
29
+ * @param {Record<string, string>} replacements A dictionary of replacements to apply.
30
+ * @returns {string} The normalized HTML string.
31
+ * @see https://maizzle.com/docs/transformers/safe-class-names
29
32
  */
30
33
  function safeClassNames(html: string, replacements: Record<string, string>): string;
31
34
 
32
35
  /**
33
- Compile Markdown to HTML.
34
-
35
- @param {string} input String to compile with Markdown.
36
- @param {Options} [options] markdown-it options.
36
+ * Compile Markdown to HTML.
37
+ *
38
+ * @param {string} input The Markdown string to compile.
39
+ * @param {MarkdownConfig} [options] A configuration object for the Markdown compiler.
40
+ * @returns {string} The compiled HTML string.
41
+ * @see https://maizzle.com/docs/transformers/markdown
37
42
  */
38
- function markdown(input: string, options?: MarkdownItOptions): string;
43
+ function markdown(input: string, options?: MarkdownConfig): string;
39
44
 
40
45
  /**
41
- Prevent widow words inside a tag by adding a `&nbsp;` between its last two words.
42
-
43
- @param {string} html The HTML string to render.
44
- @param {WidowWordsConfig} [options] Options to pass to the transformer.
45
- */
46
+ * Prevent widow words inside a tag by adding a `&nbsp;` between its last two words.
47
+ *
48
+ * @param {string} html The HTML string to process.
49
+ * @param {WidowWordsConfig} [options] A configuration object for the widow words transformer.
50
+ * @returns {string} The processed HTML string.
51
+ * @see https://maizzle.com/docs/transformers/widows
52
+ */
46
53
  function preventWidows(html: string, options?: WidowWordsConfig): string;
47
54
 
48
55
  /**
49
- Duplicate HTML attributes to inline CSS.
50
-
51
- @param {string} html The HTML string to render.
52
- @param {AttributeToStyleSupportedAttributes} [options] Options to pass to the transformer.
53
- */
56
+ * Duplicate HTML attributes to inline CSS.
57
+ *
58
+ * @param {string} html The HTML string to process.
59
+ * @param {AttributeToStyleSupportedAttributes[]} attributes An array of attributes to inline.
60
+ * @param {PostHTMLConfig} [posthtmlConfig] A configuration object for PostHTML.
61
+ * @returns {string} The processed HTML string.
62
+ * @see https://maizzle.com/docs/transformers/attribute-to-style
63
+ */
54
64
  function attributeToStyle(
55
65
  html: string,
56
- options?: AttributeToStyleSupportedAttributes[]
66
+ attributes: AttributeToStyleSupportedAttributes[],
67
+ posthtmlConfig?: PostHTMLConfig
57
68
  ): string;
58
69
 
59
70
  /**
60
- Inline CSS styles from `<style>` tags found in `<head>`.
61
-
62
- @param {string} html The HTML string to render.
63
- @param {InlineCSSConfig} [options] Options to pass to the transformer.
64
- */
65
- function inlineCSS(html: string, options?: InlineCSSConfig): string;
71
+ * Inline CSS styles in an HTML string.
72
+ *
73
+ * @param {string} html The HTML string to process.
74
+ * @param {CSSInlineConfig} [options] A configuration object for the CSS inliner.
75
+ * @returns {string} The processed HTML string.
76
+ * @see https://maizzle.com/docs/transformers/inline-css
77
+ */
78
+ function inlineCSS(html: string, options?: CSSInlineConfig): string;
66
79
 
67
80
  /**
68
- Rewrite longhand CSS inside style attributes with shorthand syntax.
69
- Only works with margin, padding and border, and only when all sides are specified.
70
-
71
- @param {string} html The HTML string to render.
72
- */
81
+ * Rewrite longhand CSS inside style attributes with shorthand syntax.
82
+ * Only works with margin, padding and border, and only when all sides are specified.
83
+ *
84
+ * @param {string} html The HTML string to process.
85
+ * @returns {string} The processed HTML string.
86
+ * @see https://maizzle.com/docs/transformers/shorthand-css
87
+ */
73
88
  function shorthandCSS(html: string): string;
74
89
 
75
90
  /**
76
- Remove unused CSS from `<style>` tags and HTML elements.
77
-
78
- @param {string} html The HTML string to use.
79
- @param {RemoveUnusedCSSConfig} [options] Options to pass to the transformer.
80
- */
81
- function removeUnusedCSS(html: string, options?: RemoveUnusedCSSConfig): string;
91
+ * Remove unused CSS from `<style>` tags and HTML elements.
92
+ *
93
+ * @param {string} html The HTML string to process.
94
+ * @param {PurgeCSSConfig} [options] A configuration object for `email-comb`.
95
+ * @returns {string} The processed HTML string.
96
+ * @see https://maizzle.com/docs/transformers/remove-unused-css
97
+ */
98
+ function removeUnusedCSS(html: string, options?: PurgeCSSConfig): string;
82
99
 
83
100
  /**
84
- Automatically remove HTML attributes.
85
- @param {string} html The HTML string to use.
86
- @param options Either an array of attribute names, or an array of objects with `name` and `value` properties.
87
- */
101
+ * Remove HTML attributes from an HTML string.
102
+ *
103
+ * @param {string} html The HTML string to process.
104
+ * @param {string[] | Array<{ name: string; value: string | RegExp }>} [options] An array of attribute names to remove, or an array of objects with `name` and `value` properties.
105
+ * @returns {string} The processed HTML string.
106
+ * @see https://maizzle.com/docs/transformers/remove-attributes
107
+ */
88
108
  function removeAttributes(
89
109
  html: string,
90
110
  options?:
@@ -96,92 +116,104 @@ declare namespace MaizzleFramework {
96
116
  ): string;
97
117
 
98
118
  /**
99
- Add attributes to elements in your HTML.
100
-
101
- @param {string} html The HTML string to use.
102
- @param {object} options Attributes to add.
103
- */
119
+ * Add attributes to elements in an HTML string.
120
+ *
121
+ * @param {string} html The HTML string to process.
122
+ * @param {Record<string, unknown>} [options] A dictionary of attributes to add.
123
+ * @returns {string} The processed HTML string.
124
+ * @see https://maizzle.com/docs/transformers/add-attributes
125
+ */
104
126
  function addAttributes(html: string, options?: Record<string, unknown>): string;
105
127
 
106
128
  /**
107
- Pretty print HTML code so that it's nicely indented and more human-readable.
108
- @param {string} html The HTML string to prettify.
109
- @param {CoreBeautifyOptions} [options] Options to pass to the prettifier.
110
- */
111
- function prettify(html: string, options?: CoreBeautifyOptions): string;
129
+ * Pretty-print an HTML string.
130
+ *
131
+ * @param {string} html The HTML string to prettify.
132
+ * @param {HTMLBeautifyOptions} [options] A configuration object for `js-beautify`.
133
+ * @returns {string} The prettified HTML string.
134
+ * @see https://maizzle.com/docs/transformers/prettify
135
+ */
136
+ function prettify(html: string, options?: HTMLBeautifyOptions): string;
112
137
 
113
138
  /**
114
- Prepend a string to sources and hrefs in an HTML string.
115
-
116
- @param {string} html The HTML string to use.
117
- @param {BaseURLConfig} [options] Options to pass to the transformer.
118
- */
139
+ * Prepend a string to sources and hrefs in an HTML string.
140
+ *
141
+ * @param {string} html The HTML string to process.
142
+ * @param {string | BaseURLConfig} [options] A string to prepend to sources and hrefs, or a configuration object for `posthtml-base-url`.
143
+ * @returns {string} The processed HTML string.
144
+ * @see https://maizzle.com/docs/transformers/base-url
145
+ */
119
146
  function applyBaseURL(html: string, options?: string | BaseURLConfig): string;
120
147
 
121
148
  /**
122
- Append parameters to URLs in an HTML string.
123
- @param {string} html The HTML string to use.
124
- @param {URLParametersConfig} [options] Options to pass to the transformer.
125
- */
149
+ * Append parameters to URLs in an HTML string.
150
+ *
151
+ * @param {string} html The HTML string to process.
152
+ * @param {URLParametersConfig} [options] A configuration object for `posthtml-url-parameters`.
153
+ * @returns {string} The processed HTML string.
154
+ * @see https://maizzle.com/docs/transformers/url-parameters
155
+ */
126
156
  function addURLParameters(html: string, options?: URLParametersConfig): string;
127
157
 
128
158
  /**
129
- Ensure that all your HEX colors inside `bgcolor` and `color` attributes are defined with six digits.
130
-
131
- @param {string} html The HTML string to use.
132
- */
133
- function ensureSixHex(html: string): string;
159
+ * Ensure that all HEX colors inside `bgcolor` and `color` attributes are defined with six digits.
160
+ *
161
+ * @param {string} html The HTML string to process.
162
+ * @returns {string} The processed HTML string.
163
+ * @see https://maizzle.com/docs/transformers/six-hex
164
+ */
165
+ function sixHEX(html: string): string;
134
166
 
135
167
  /**
136
- Minify a string of HTML code.
137
-
138
- @param {string} html The HTML string to minify.
139
- @param {MinifyConfig} [options] Options to pass to the minifier.
140
- */
168
+ * Minify an HTML string, with email client considerations.
169
+ *
170
+ * @param {string} html The HTML string to minify.
171
+ * @param {MinifyConfig} [options] A configuration object for `html-minifier`.
172
+ * @returns {string} The minified HTML string.
173
+ * @see https://maizzle.com/docs/transformers/minify
174
+ */
141
175
  function minify(html: string, options?: MinifyConfig): string;
142
176
 
143
177
  /**
144
- Batch-replace strings in an HTML string.
145
-
146
- @param {string} html The HTML string to use.
147
- @param {object} replacements Strings to find and replace.
148
- */
178
+ * Batch-replace strings in an HTML string.
179
+ *
180
+ * @param {string} html The HTML string to process.
181
+ * @param {Record<string, string>} [replacements] A dictionary of strings to replace.
182
+ * @returns {string} The processed HTML string.
183
+ * @see https://maizzle.com/docs/transformers/replace-strings
184
+ */
149
185
  function replaceStrings(html: string, replacements?: Record<string, string>): string;
150
186
 
151
187
  /**
152
- Generate a plaintext version of an HTML string.
153
-
154
- @param {string} html The HTML string to use.
155
- @param {PlaintextConfig} [options] Options to pass to the plaintext generator.
156
- */
157
- function plaintext(html: string, options?: PlaintextConfig): Promise<{
158
- html: string;
159
- plaintext: string;
160
- destination: string;
161
- }>;
188
+ * Generate a plaintext version of an HTML string.
189
+ * @param {string} html - The HTML string to convert to plaintext.
190
+ * @param {PlaintextConfig} [options] - A configuration object for the plaintext generator.
191
+ * @returns {Promise<string>} The plaintext version of the HTML string.
192
+ * @see https://maizzle.com/docs/plaintext
193
+ */
194
+ function plaintext(html: string, options?: PlaintextConfig): Promise<string>;
162
195
 
163
196
  export {
164
197
  Config,
165
- RenderOptions,
166
- // Functions
167
- addAttributes,
168
- addURLParameters,
169
- applyBaseURL,
170
- attributeToStyle,
171
- ensureSixHex,
172
- inlineCSS,
198
+ render,
199
+ safeClassNames,
173
200
  markdown,
174
- minify,
175
- plaintext,
176
201
  preventWidows,
177
- prettify,
178
- removeAttributes,
202
+ attributeToStyle,
203
+ inlineCSS,
204
+ shorthandCSS,
179
205
  removeUnusedCSS,
180
- render,
206
+ removeUnusedCSS as purgeCSS,
207
+ removeAttributes,
208
+ addAttributes,
209
+ prettify,
210
+ applyBaseURL,
211
+ addURLParameters as addUrlParams,
212
+ sixHEX,
213
+ minify,
181
214
  replaceStrings,
182
- safeClassNames,
183
- shorthandCSS
184
- };
215
+ plaintext,
216
+ }
185
217
  }
186
218
 
187
219
  export = MaizzleFramework;
@@ -1,31 +1,33 @@
1
- import type {Options as MarkdownItOptions} from 'markdown-it';
1
+ import type { Options as MarkdownItOptions } from 'markdown-it';
2
2
 
3
3
  export default interface MarkdownConfig {
4
4
  /**
5
- Path relative to which markdown files are imported.
6
-
7
- @default './'
8
- */
5
+ * Path relative to which markdown files are imported.
6
+ *
7
+ * @default './'
8
+ */
9
9
  root?: string;
10
10
 
11
11
  /**
12
- Encoding for imported Markdown files.
13
-
14
- @default 'utf8'
15
- */
12
+ * Encoding for imported Markdown files.
13
+ *
14
+ * @default 'utf8'
15
+ */
16
16
  encoding?: string;
17
17
 
18
18
  /**
19
- Options to pass to the `markdown-it` library.
20
-
21
- @default {}
22
- */
19
+ * Options to pass to the `markdown-it` library.
20
+ *
21
+ * @default {}
22
+ */
23
23
  markdownit?: MarkdownItOptions;
24
24
 
25
25
  /**
26
- Plugins for the `markdown-it` library.
27
-
28
- @default []
29
- */
30
- plugins?: any[];
26
+ * Plugins for the `markdown-it` library.
27
+ * @default []
28
+ */
29
+ plugins?: Array<{
30
+ plugin: string;
31
+ options: Record<string, unknown>;
32
+ }>;
31
33
  }
package/types/minify.d.ts CHANGED
@@ -1,136 +1,138 @@
1
+ import type { Opts } from 'html-crush';
2
+
1
3
  export default interface MinifyConfig {
2
4
  /**
3
- Maximum line length. Works only when `removeLineBreaks` is `true`.
4
-
5
- @default 500
6
- */
7
- lineLengthLimit?: number;
5
+ * Maximum line length. Works only when `removeLineBreaks` is `true`.
6
+ *
7
+ * @default 500
8
+ */
9
+ lineLengthLimit?: Opts['lineLengthLimit'];
8
10
 
9
11
  /**
10
- Remove all line breaks from HTML when minifying.
11
-
12
- @default true
13
- */
14
- removeLineBreaks?: boolean;
12
+ * Remove all line breaks from HTML when minifying.
13
+ *
14
+ * @default true
15
+ */
16
+ removeLineBreaks?: Opts['removeLineBreaks'];
15
17
 
16
18
  /**
17
- Remove code indentation when minifying HTML.
18
-
19
- @default true
19
+ * Remove code indentation when minifying HTML.
20
+ *
21
+ * @default true
20
22
  */
21
- removeIndentations?: boolean;
23
+ removeIndentations?: Opts['removeIndentations'];
22
24
 
23
25
  /**
24
- Remove `<!-- HTML comments -->` when minifying HTML.
25
-
26
- `0` - don't remove any HTML comments
27
-
28
- `1` - remove all comments except Outlook conditional comments
29
-
30
- `2` - remove all comments, including Outlook conditional comments
31
-
32
- @default false
33
- */
34
- removeHTMLComments?: boolean | number;
26
+ * Remove `<!-- HTML comments -->` when minifying HTML.
27
+ *
28
+ * `0` - don't remove any HTML comments
29
+ *
30
+ * `1` - remove all comments except Outlook conditional comments
31
+ *
32
+ * `2` - remove all comments, including Outlook conditional comments
33
+ *
34
+ * @default false
35
+ */
36
+ removeHTMLComments?: Opts['removeHTMLComments'];
35
37
 
36
38
  /**
37
- Remove CSS comments when minifying HTML.
38
-
39
- @default true
40
- */
41
- removeCSSComments?: boolean;
39
+ * Remove CSS comments when minifying HTML.
40
+ *
41
+ * @default true
42
+ */
43
+ removeCSSComments?: Opts['removeCSSComments'];
42
44
 
43
45
  /**
44
- When any of given strings are encountered and `removeLineBreaks` is true, current line will be terminated.
45
-
46
- @default
47
- [
48
- '</td',
49
- '<html',
50
- '</html',
51
- '<head',
52
- '</head',
53
- '<meta',
54
- '<link',
55
- '<table',
56
- '<script',
57
- '</script',
58
- '<!DOCTYPE',
59
- '<style',
60
- '</style',
61
- '<title',
62
- '<body',
63
- '@media',
64
- '</body',
65
- '<!--[if',
66
- '<!--<![endif',
67
- '<![endif]'
68
- ]
69
- */
70
- breakToTheLeftOf?: string[] | boolean | null;
46
+ * When any of given strings are encountered and `removeLineBreaks` is true, current line will be terminated.
47
+ *
48
+ * @default
49
+ * [
50
+ * '</td',
51
+ * '<html',
52
+ * '</html',
53
+ * '<head',
54
+ * '</head',
55
+ * '<meta',
56
+ * '<link',
57
+ * '<table',
58
+ * '<script',
59
+ * '</script',
60
+ * '<!DOCTYPE',
61
+ * '<style',
62
+ * '</style',
63
+ * '<title',
64
+ * '<body',
65
+ * '@media',
66
+ * '</body',
67
+ * '<!--[if',
68
+ * '<!--<![endif',
69
+ * '<![endif]'
70
+ * ]
71
+ */
72
+ breakToTheLeftOf?: Opts['breakToTheLeftOf'];
71
73
 
72
74
  /**
73
- Some inline tags can accidentally introduce extra text.
74
- The minifier will take extra precaution when minifying around these tags.
75
-
76
- @default
77
- [
78
- 'a',
79
- 'abbr',
80
- 'acronym',
81
- 'audio',
82
- 'b',
83
- 'bdi',
84
- 'bdo',
85
- 'big',
86
- 'br',
87
- 'button',
88
- 'canvas',
89
- 'cite',
90
- 'code',
91
- 'data',
92
- 'datalist',
93
- 'del',
94
- 'dfn',
95
- 'em',
96
- 'embed',
97
- 'i',
98
- 'iframe',
99
- 'img',
100
- 'input',
101
- 'ins',
102
- 'kbd',
103
- 'label',
104
- 'map',
105
- 'mark',
106
- 'meter',
107
- 'noscript',
108
- 'object',
109
- 'output',
110
- 'picture',
111
- 'progress',
112
- 'q',
113
- 'ruby',
114
- 's',
115
- 'samp',
116
- 'script',
117
- 'select',
118
- 'slot',
119
- 'small',
120
- 'span',
121
- 'strong',
122
- 'sub',
123
- 'sup',
124
- 'svg',
125
- 'template',
126
- 'textarea',
127
- 'time',
128
- 'u',
129
- 'tt',
130
- 'var',
131
- 'video',
132
- 'wbr'
133
- ]
134
- */
135
- mindTheInlineTags?: string[] | boolean | null;
75
+ * Some inline tags can accidentally introduce extra text.
76
+ * The minifier will take extra precaution when minifying around these tags.
77
+ *
78
+ * @default
79
+ * [
80
+ * 'a',
81
+ * 'abbr',
82
+ * 'acronym',
83
+ * 'audio',
84
+ * 'b',
85
+ * 'bdi',
86
+ * 'bdo',
87
+ * 'big',
88
+ * 'br',
89
+ * 'button',
90
+ * 'canvas',
91
+ * 'cite',
92
+ * 'code',
93
+ * 'data',
94
+ * 'datalist',
95
+ * 'del',
96
+ * 'dfn',
97
+ * 'em',
98
+ * 'embed',
99
+ * 'i',
100
+ * 'iframe',
101
+ * 'img',
102
+ * 'input',
103
+ * 'ins',
104
+ * 'kbd',
105
+ * 'label',
106
+ * 'map',
107
+ * 'mark',
108
+ * 'meter',
109
+ * 'noscript',
110
+ * 'object',
111
+ * 'output',
112
+ * 'picture',
113
+ * 'progress',
114
+ * 'q',
115
+ * 'ruby',
116
+ * 's',
117
+ * 'samp',
118
+ * 'script',
119
+ * 'select',
120
+ * 'slot',
121
+ * 'small',
122
+ * 'span',
123
+ * 'strong',
124
+ * 'sub',
125
+ * 'sup',
126
+ * 'svg',
127
+ * 'template',
128
+ * 'textarea',
129
+ * 'time',
130
+ * 'u',
131
+ * 'tt',
132
+ * 'var',
133
+ * 'video',
134
+ * 'wbr'
135
+ * ]
136
+ */
137
+ mindTheInlineTags?: Opts['mindTheInlineTags'];
136
138
  }