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

SyntaxError: Illegal 'use strict' directive #1063

Open
hlehmann opened this issue Jun 9, 2022 · 9 comments
Open

SyntaxError: Illegal 'use strict' directive #1063

hlehmann opened this issue Jun 9, 2022 · 9 comments

Comments

@hlehmann
Copy link

hlehmann commented Jun 9, 2022

While compiling with vite we get the following error:

SyntaxError: Illegal 'use strict' directive in function with non-simple parameter list 
in node_modules/localforage/dist/localforage.js(8:1) 

It seems the bundle doesn't respect usage of "use strict"

@victorst79
Copy link

victorst79 commented Jun 15, 2022

Same here, error in build process with Vite.

[commonjs] Illegal 'use strict' directive in function with non-simple parameter list (8:1) in /node_modules/.pnpm/[email protected]/node_modules/localforage/dist/localforage.js

package:

{
  "vite": "^2.9.9",
  "localforage": "^1.10.0",
}

@web-dev-s
Copy link

web-dev-s commented Jun 28, 2022

Same even here in build with vite:
[commonjs] Illegal 'use strict' directive in function with non-simple parameter list (8:1) in /node_modules/localforage/dist/localforage.js

package:

{
"vite": "^2.9.12",
"localforage": "^1.10.0",
}

@thril
Copy link

thril commented Jul 29, 2022

The same error occurs with vite v3.0.0.

@trevorglick
Copy link

ran into this as well.

@ragheed-affas
Copy link

facing the same issue as well

{
  "vite": "^3.0.0",
  "localforage": "^1.10.0",
}

@MarcelKlammer
Copy link

Same issue. Quasar + Vite + LF 1.10.0

@lbartroli
Copy link

same issue, is there a workaround for this?

@thril
Copy link

thril commented Oct 6, 2022

Since there hasn't been any movement in this repo for over a year, I suspect this won't get addressed any time soon, or probably ever. We've moved away from localforage and simply use localStorage since we didn't actually need any of the goodies that localforage provided. Good luck!

@nottagg
Copy link

nottagg commented May 15, 2023

Anyone find a workaround with this? Also seeing this while moving to vite

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

9 participants