MCPcopy
hub / github.com/SparkPost/heml / renderHemlFile

Function renderHemlFile

packages/heml/src/bin/utils/renderHemlFile.js:4–11  ·  view source on GitHub ↗
(filepath, options)

Source from the content-addressed store, hash-verified

2import heml from '../../'
3
4async function renderHemlFile (filepath, options) {
5 const contents = await readFile(filepath, 'utf8')
6 const startTime = process.hrtime()
7 const results = await heml(contents, options)
8 results.metadata.time = Math.round(process.hrtime(startTime)[1] / 1000000)
9
10 return results
11}
12
13export default renderHemlFile

Callers 2

developFunction · 0.85
buildFunction · 0.85

Calls 1

hemlFunction · 0.85

Tested by

no test coverage detected