1

I'm trying to import a package inside an old coffe script file:

import Quill from 'quill/core'

But keep getting the error:

Uncaught SyntaxError: Cannot use import statement outside a module

I set type: module inside the package.json file too. The import also is working in Vue files.

temp
  • 519
  • 7
  • 18
  • No it doesn't that's why I asked a new question. – temp Jan 11 '23 at 11:50
  • If the other question doesn't help. could you give some more info? What version of coffeescript and node are you using? Any transpilers? Could you make a minimal coffee file to reproduce the error? Including how the coffee file is loaded into your project? – caffeinated.tech Jan 11 '23 at 15:21
  • 1
    @caffeinated.tech I gladly got it solved. Including packages ain't supported in the old project. I had to manually include the code. But thanks! – temp Jan 12 '23 at 08:13

0 Answers0