aui / art-template

High performance JavaScript templating engine

Home Page:https://aui.github.io/art-template/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Doesn't work with bun.js because require.extensions[template.defaults.extname] = extension; looks like it's not supported

turbobuilt opened this issue · comments

Hi no speak chinese :)

Apparently this line of code is deprecated. It doesn't work with Bun.js. Is there a workaround? Thank you! This is a great library

const template = require('./lib/index');
const extension = require('./lib/extension');

template.extension = extension;
>>> require.extensions[template.defaults.extname] = extension;

module.exports = template;

TypeError: undefined is not an object (evaluating 'import.meta.require.extensions[template.defaults.extname] = extension')