pilcrowonpaper / oslo

A collection of auth-related utilities
https://oslo.js.org
MIT License
1.06k stars 35 forks source link

Unexpected character '�' #43

Closed asterikx closed 5 months ago

asterikx commented 8 months ago

I get the following error in a SolidStart project (i.e. using Vite) after upgrading to oslo@1.1.0:

[commonjs--resolver] Unexpected character '�' (Note that you need plugins to import files that are not JavaScript)
file: /Users/erikmuller/cn-webapp/node_modules/@node-rs/argon2/index.js:1:0
1: ����
       ���__TEXT@__text...
   ^
2: �H__LINKEDIT�
�/Users/runner/work/node-rs/node-rs/target/aarch6...

[12:36:09 AM]  ERROR  Unexpected character '�' (Note that you need plugins to import files that are not JavaScript)

  at error (node_modules/vinxi/node_modules/vite/node_modules/rollup/dist/es/shared/node-entry.js:2287:30)
  at Module.error (node_modules/vinxi/node_modules/vite/node_modules/rollup/dist/es/shared/node-entry.js:13745:16)
  at Module.tryParse (node_modules/vinxi/node_modules/vite/node_modules/rollup/dist/es/shared/node-entry.js:14476:25)
  at Module.setSource (node_modules/vinxi/node_modules/vite/node_modules/rollup/dist/es/shared/node-entry.js:14077:39)
  at ModuleLoader.addModuleSource (node_modules/vinxi/node_modules/vite/node_modules/rollup/dist/es/shared/node-entry.js:24649:20)

The issue has also been reported for SvelteKit project here and the resolution proposed in this post doesn't work for me.

pilcrowonpaper commented 8 months ago

Did you install it as a dev dependency?

asterikx commented 8 months ago

No, I installed oslo@1.1.1 as a regular dependency.

pilcrowonpaper commented 8 months ago

Can you try the solution in the Vite section? https://lucia-auth.com/getting-started/#vite

pilcrowonpaper commented 5 months ago

Closing this due to a lack of activity