// @ts-ignore
import scribe from 'scribe.js-ocr';
scribe.extractText(file).then((text: string) => {
console.log('Extracted text:', text);
});
This gives error: require() cannot be used on an ESM graph with top-level await. Use import() instead.
Is there something I am missing?