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

Can't resolve 'fs' and 'fileURLToPath' was not found in 'url' #384

Open
howdu opened this issue Mar 17, 2022 · 1 comment
Open

Can't resolve 'fs' and 'fileURLToPath' was not found in 'url' #384

howdu opened this issue Mar 17, 2022 · 1 comment

Comments

@howdu
Copy link

howdu commented Mar 17, 2022

Since upgrading @cityssm/simple-password-generator from version 2.0.2 to 2.1.1 getting the follwing errors:
ERROR in ./node_modules/@cityssm/unleet/translations.js 1:0-25
Module not found: Error: Can't resolve 'fs' in '/node_modules/@cityssm/unleet'

ERROR in ./node_modules/@cityssm/unleet/translations.js 3:25-38
export 'fileURLToPath' (imported as 'fileURLToPath') was not found in 'url' (possible exports: Url, format, parse, resolve, resolveObject)

Looks to be changes from this commit.
e22e5a4

I'm using Laravel Mix with webpack for building js.

I've tried adding this which seems to fix the first issue but the second is still present:

mix.webpackConfig({
    resolve: {
        fallback: {
            "fs": false,
            "path": false,
            "os": false,
        }
    }
});
@dangowans
Copy link
Member

Interesting. I'm sorry to hear things aren't working for you anymore.

I'm not familiar with Laravel Mix or webpack, so forgive me if I don't have a quick answer.

If I'm reading the Node documentation correctly, fileURLToPath has been included in url since Node v10.12.0. What version of Node are you running?

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

2 participants