Skip to content

error TS1192: Module '"node:fs"' has no default export. #584

@axi92

Description

@axi92

I don't know if my setup is the problem but I get this error from my nest project.

If I change the imports to: import { PathLike } from 'node:fs'; and replace all fs.PathLike with PathLike it works.

https://github.com/typicode/lowdb/blob/main/src/adapters/node/TextFile.ts#L1
https://github.com/typicode/lowdb/blob/main/src/presets/node.ts#L1

If this is not a valid issue and my setup is the problem, please let me know - first time working with typescript.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions