Skip to content

Commit 2c34a4a

Browse files
committed
new 2.0.0 release
1 parent aa26dee commit 2c34a4a

File tree

2 files changed

+8
-5
lines changed

2 files changed

+8
-5
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ You're your curious to [learn about the tool's history](https://github.com/freet
1616
1717
## Supported NodeJS Versions
1818

19-
Current 2.x version of `inline-email` are tested against NodeJS 8.x -> 12.x.
19+
Current 2.x version of `inline-email` are tested against NodeJS 8.x -> 11.x.
2020
The 2.x will work on version 6.x and 8.x, but the test runners no longer support these so validation is not guaranteed.
2121

2222
Previous 1.x versions of `inline-email` support NodeJS 6.x -> 9.x. Older NodeJS will not work with this package.

lib/render.js

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,13 @@
1-
'use strict;'
1+
'use strict';
22

33
const Inky = require('inky').Inky;
44
const Juice = require('juice');
55
const Hoek = require('@hapi/hoek');
66

7-
module.exports = (htmlFile, cssFile, options = { inky: { enabled: true }, juice: { linkCss: false, webResources: { images: false } } }) => {
7+
module.exports = (htmlFile, cssFile, options = {
8+
inky: {enabled: true},
9+
juice: {linkCss: false, webResources: {images: false}}
10+
}) => {
811
return new Promise((resolve, reject) => {
912
Hoek.assert(htmlFile || htmlFile === '', new Error('HTML file is required!'));
1013

@@ -13,7 +16,7 @@ module.exports = (htmlFile, cssFile, options = { inky: { enabled: true }, juice:
1316
const inky = new Inky(options.inky);
1417
convertedHtml = inky.releaseTheKraken(htmlFile);
1518
}
16-
19+
1720
if (options.juice.linkCss) {
1821
Juice.juiceResources(options.inky.enabled ? convertedHtml : htmlFile, options.juice, (err, htmlResult) => {
1922
if (err) {
@@ -26,4 +29,4 @@ module.exports = (htmlFile, cssFile, options = { inky: { enabled: true }, juice:
2629
return resolve(Juice.inlineContent(options.inky.enabled ? convertedHtml : htmlFile, cssFile || '', options.juice))
2730
}
2831
})
29-
}
32+
};

0 commit comments

Comments
 (0)