@maizzle/framework 5.0.7 → 5.0.8

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@maizzle/framework",
3
- "version": "5.0.7",
3
+ "version": "5.0.8",
4
4
  "description": "Maizzle is a framework that helps you quickly build HTML emails with Tailwind CSS.",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -98,8 +98,10 @@ export async function process(html = '', config = {}) {
98
98
  [].concat(componentsConfig.fileExtension)
99
99
  ))
100
100
 
101
+ const beforePlugins = get(config, 'posthtml.plugins.before', [])
102
+
101
103
  return posthtml([
102
- ...get(config, 'posthtml.plugins.before', []),
104
+ ...beforePlugins,
103
105
  envTags(config.env),
104
106
  envAttributes(config.env),
105
107
  expandLinkTag,
@@ -110,7 +112,13 @@ export async function process(html = '', config = {}) {
110
112
  postcssPlugin,
111
113
  envTags(config.env),
112
114
  envAttributes(config.env),
113
- ...get(config, 'posthtml.plugins.after', get(config, 'posthtml.plugins', []))
115
+ ...get(
116
+ config,
117
+ 'posthtml.plugins.after',
118
+ beforePlugins.length > 0
119
+ ? []
120
+ : get(config, 'posthtml.plugins', [])
121
+ ),
114
122
  ])
115
123
  .process(html, posthtmlOptions)
116
124
  .then(result => ({