pilcrowonpaper / oslo

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

Module parse failed: Unexpected character '�' (1:0) #57

Closed William-McGonagle closed 7 months ago

William-McGonagle commented 7 months ago

I have a Next.js 14 project set up with the pages router. But, as I am setting up Lucia (I'm following the Username and Password Tutorial to set it up. But, I keep getting the following error message.

./node_modules/.pnpm/@node-rs+argon2-darwin-x64@1.7.0/node_modules/@node-rs/argon2-darwin-x64/argon2.darwin-x64.node
Module parse failed: Unexpected character '�' (1:0)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
(Source code omitted for this binary file)

I'm using PNPM as the package manager but I don't think that should cause any problems.

pilcrowonpaper commented 7 months ago

Did you configure Webpack as described in the docs?

https://lucia-auth.com/getting-started/nextjs-app#update-configuration

William-McGonagle commented 7 months ago

Worked like a charm! Thank you @pilcrowOnPaper.