ejs
ejs copied to clipboard
Update ejs.js
identify and remove BOM header.
new function: line = 52
/**
- Render an EJS file at the given
path(easton changed) - @param {String} path
- @param {String} encoding
- @api private */ function readEJSFile(path, encoding) { var buffer = read(path); if (buffer[0] == 239 && buffer[1] == 187 && buffer[2] == 191) { buffer = buffer.slice(3); } return buffer.toString(encoding); }
Is this the same as this rejected PR in express-handlerbars? https://github.com/ericf/express-handlebars/issues/77#issuecomment-54659830
I submitted a update, in Apr. but nobody reply.