Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error: unexpected top-level await at node_modules/ttf2woff2/dist/index.js:9 #207

Closed
timint opened this issue Nov 10, 2024 · 1 comment
Closed

Comments

@timint
Copy link
Contributor

timint commented Nov 10, 2024

Error: unexpected top-level await at node_modules/ttf2woff2/dist/index.js:9

ttf2woff2 = (await import('bindings')).default('addon.node').convert;

Using Node v23.1.0. I tried upgrading image2woff2 to 6.0.1 but the error remains.

From my gulpfile.mjs:

import iconfont from 'gulp-iconfont';

I also tried this:

import { createRequire } from 'node:module';
const require = createRequire(import.meta.url);

const iconfont = require('gulp-iconfont');
@timint
Copy link
Contributor Author

timint commented Nov 20, 2024

@timint timint closed this as completed Nov 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant