Replies: 9 comments 4 replies
-
I tried updating Node.js and the error went away |
Beta Was this translation helpful? Give feedback.
-
still same issue please help |
Beta Was this translation helpful? Give feedback.
-
I had the same problem, but found I had a composer.json file in the parent folder of my project that was overriding the local file. Once I removed that, I had no issues. |
Beta Was this translation helpful? Give feedback.
-
By updating the node version, The issue is resolved. |
Beta Was this translation helpful? Give feedback.
-
My Node.js version when i run node -v returns v.18.20.6 but when i use vite to create a react app I keep getting this `SyntaxError: The requested module 'node:fs/promises' does not provide an export named 'constants' Node.js v17.7.1` which indicates i have Node.js v17.71 I've tried uninstalling node and reinstalling, switch to node 18 and uninstalling and reinstalling nvm as well. But i keep getting the same error. Please help |
Beta Was this translation helpful? Give feedback.
-
We had Node |
Beta Was this translation helpful? Give feedback.
-
Getting this error on import fsp, { constants as constants$9 } from 'node:fs/promises';
^^^^^^^^^
SyntaxError: The requested module 'node:fs/promises' does not provide an export named 'constants'
at ModuleJob._instantiate (node:internal/modules/esm/module_job:124:21)
at async ModuleJob.run (node:internal/modules/esm/module_job:181:5)
at async Promise.all (index 0)
at async ESMLoader.import (node:internal/modules/esm/loader:281:24) |
Beta Was this translation helpful? Give feedback.
-
Updated node and had to reboot - now works |
Beta Was this translation helpful? Give feedback.
-
This issue persisted to me while i was on node v16.6.0 version, i shifted my version to node v18.2.0 using nvm and it worked as expected |
Beta Was this translation helpful? Give feedback.
-
import fsp, { constants as constants$9 } from 'node:fs/promises';
^^^^^^^^^
SyntaxError: The requested module 'node:fs/promises' does not provide an export named 'constants'
Beta Was this translation helpful? Give feedback.
All reactions