-
Notifications
You must be signed in to change notification settings - Fork 23
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
[BUG] You may need an appropriate loader to handle this file type #70
Comments
Hello Jawad. We may need a little more context to analyze this weird error (what does Nuxt mean with "this file type" ?? it's only a single JavaScript file after all). However, without knowing why you get this error, I can say that other users have reported issues with SSR frameworks like Nuxt and have found solutions. Have you tried that ? |
I'm using it in Nuxt , this is VueJs frame work and its a SSR framework. ` in ./node_modules/client-zip/index.js friendly-errors 20:09:55 Module parse failed: Unexpected token (1:1499) friendly-errors 20:09:55
|
Thanks, that settles it. Your Nuxt toolchain is set up to read "old" JavaScript and it can't parse the optional chaining operator You could try to upgrade the transpilation target for Nuxt to ES2020 and hope there isn't an intermediate step that you can't touch with your config files. Or, if you never create archives larger than 4 GB, just use client-zip version 1.x (which doesn't need BigInts and is already transpiled to ES2018). |
Thanks downgrading to 1.x works |
Resolved with downgrading to version 1.x |
Describe the bug
In my Nuxt project I'm using in component like and its giving the error
You may need an appropriate loader to handle this file type
To Reproduce
Steps to reproduce the behavior:
add import in vue component
import { downloadZip } from "client-zip";
any solution to this error
The text was updated successfully, but these errors were encountered: