question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Can't use fs module in the static.config.js file

See original GitHub issue

I wanted to create markdown files inside a folder, but when I tried to use the fs module (or fs-extra) the build process fails. Minimum steps: Add import fs from 'fs' to the static.config.js file $ yarn start screen shot 2017-10-07 at 3 56 49 pm

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:10 (6 by maintainers)

github_iconTop GitHub Comments

3reactions
tannerlinsleycommented, Oct 9, 2017

Should be good now. Confirm again?

1reaction
tannerlinsleycommented, Oct 9, 2017

This should be fixed in the latest release (4b2a6db50ff48e6f21f71033a7a6ced623fa6839, react-static@1.0.41). Can either of you confirm?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Module not found: Can't resolve 'fs' in Next.js application
If you use fs , be sure it's only within getInitialProps or getServerSideProps . (anything includes server-side rendering).
Read more >
Can't use fs module in the static.config.js file · Issue #6 - GitHub
I wanted to create markdown files inside a folder, but when I tried to use the fs module (or fs-extra) the build process...
Read more >
Can't resolve 'fs' error in Next.js and WebPack - Nsikak Imoh
The Module not found: Can't resolve 'fs' in Next.js error occurs when you import a Node.js module that is available on the server-side,...
Read more >
How To Solve Module Not Found Can't Resolve 'fs' in Next.js
This error seems straightforward: the filesystem module is not found. Maybe it was not installed or something like that. However, what made this ......
Read more >
Module not found | Can't resolve 'fs' in Next js application
Join this channel to get access to perks:https://www.youtube.com/channel/UCoSpmr2KNOxjwE_B9ynUmig/joinMy GearCamera ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found