posthtml / posthtml-modules

Modules Plugin
MIT License
84 stars 11 forks source link

fix: locals option and no content passed #63

Closed cossssmin closed 3 years ago

cossssmin commented 3 years ago

This PR fixes a regression introduced in v0.7.2 where locals passed in the plugin options were parsed no matter if node.content existed or not, resulting in a TypeError: Cannot read property 'tag' of undefined when you didn't pass any content to a module (i.e. you wanted to use it as an include rather than a module).

Scrum commented 3 years ago

@cossssmin publish v0.7.3