fix: ESM bundle for Node.js, #739

This commit is contained in:
Yang Jun
2024-08-28 00:31:59 +08:00
committed by Jun Yang
parent 7c4bd7ee68
commit ce84cd6f43
6 changed files with 21 additions and 20 deletions
+2 -2
View File
@@ -3,7 +3,7 @@ import { drainStream } from '../stub/stream'
describe('.renderToNodeStream()', function () {
it('should render to stream in Node.js', done => {
const cjs = require('../../dist/liquid.node.cjs')
const cjs = require('../../dist/liquid.node')
const engine = new cjs.Liquid()
const tpl = engine.parseFileSync(resolve(__dirname, '../stub/root/foo.html'))
const stream = engine.renderToNodeStream(tpl)
@@ -28,7 +28,7 @@ describe('.renderToNodeStream()', function () {
describe('.renderFileToNodeStream()', function () {
it('should render to stream in Node.js', async () => {
const cjs = require('../../dist/liquid.node.cjs')
const cjs = require('../../dist/liquid.node')
const engine = new cjs.Liquid({
root: resolve(__dirname, '../stub/root/')
})