[Bug]: Cannot find module '@fluentui/react' or its corresponding type declarations.
Library
React / v8 (@fluentui/react)
System Info
System:
OS: Windows 10 10.0.22000
CPU: (8) x64 Intel(R) Core(TM) i5-10210U CPU @ 1.60GHz
Memory: 5.92 GB / 15.76 GB
Browsers:
Edge: Spartan (44.22000.120.0), Chromium (104.0.1293.63)
Internet Explorer: 11.0.22000.120
Are you reporting Accessibility issue?
no
Reproduction
N/A
Bug Description
Actual Behavior
After updating the @fluentui/react with 8.90.2 version, I started getting error "Cannot find module '@fluentui/react' or its corresponding type declarations". in SPFx solution(version 1.15.2). version 8.90.1 and 8.90.0 working fine.

Expected Behavior
should work similar to previous release.
Logs
No response
Requested priority
High
Products/sites affected
N/A
Are you willing to submit a PR to fix?
no
Validations
- [X] Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
- [X] The provided reproduction is a minimal reproducible example of the bug.
I'm getting the same error :
import { Stack } from "@fluentui/react"
Found 62 errors in 9600 ms
raphy@pc:~/FPlayground$ yarn add --dev @types/@fluentui/react
yarn add v1.22.19
[1/4] Resolving packages...
error Command failed.
Exit code: 128
Command: git
Arguments: ls-remote --tags --heads ssh://[email protected]/fluentui/react.git
Directory: /home/raphy/FPlayground
Output:
[email protected]: Permission denied (publickey).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
info Visit https://yarnpkg.com/en/docs/cli/add for documentation about this command.
raphy@pc:~/FPlayground$
Other Info:
O.S.: Ubuntu 20.04 Dekstop
node: v16.15.1
"@fluentui/react": "^8.90.2"
This is related to #24464
Ok, I spun up a local create react app and am able to repro this issue. I'm looking into it.
We found the bug in our publishing code. We'll have a PR up shortly and release another version.
This is set as closed, but the errors are still present for me. I have deleted node_modules and have re-installed @FluentUI
Can anyone confirm that this is fixed?

still see this message after re-installing @fluentui
@rudymiked version 8.90.2 is marked as deprecated. version 8.90.1 is the latest active version. As confirmed by @micahgodbolt new version with the fix will be released soon.

Does this effect packages other than @fluentui/react? I can't get my node_modules in an existing project back in to a working state as some dependencies of @fluentui/react (like @fluentui/react-hooks) seem to show the same problem. Trying to install an earlier version of @fluentui/react still installs latest versions of dependencies which are broken.
These errors occur on v8.11.x as well (@fluentui/[email protected]).
I deleted node modules and reinstalled packages (using 'npm install'), but I still receive errors.
I cannot make any version of @fluentui/react working as long as it needs install now
Facing same problem while building the project. Had to switch to office-fabric-ui-react for time being. SPFx version 1.15.2
This is still not working for us. Please share if anyone has found a solution or workaround.
Hey, have had the same issue since yesterday. My fluent-UI version is "@fluentui/react": "^8.72.0", my react version 17 everything work on sendbox when build I'm getting the same errors as the thread owner gets Error: Can't resolve '@fluentui/react-hooks' in '/app/node_modules/@fluentui/react/lib/c
hello @micahgodbolt, I am still facing the same issue, have delete node_modules and package-lock file, and reinstall modules. but no luck, i have tried with 8.90.2 and 8.91.0 version of fluentUI
Same problem with 8.91.0 version
same with 8.90.2 version
Also seeing the same when using 8.90.2 @micahgodbolt
The workaround is to use previous version of these packages:
With yarn:
"resolutions": {
"@fluentui/react-hooks": "8.6.7",
"@fluentui/style-utilities": "8.7.7",
"@fluentui/foundation-legacy": "8.2.15",
"@fluentui/font-icons-mdl2": "8.4.8",
"@fluentui/react-focus": "8.8.0",
"@uifabric/styling**/@fluentui/theme": "1.7.7",
"@fluentui/react/**/@fluentui/theme": "2.6.12"
},
With npm (8.3.0+):
"overrides": {
"@fluentui/react": {
"@fluentui/react-hooks": "8.6.7",
"@fluentui/style-utilities": "8.7.7",
"@fluentui/foundation-legacy": "8.2.15",
"@fluentui/font-icons-mdl2": "8.4.8",
"@fluentui/react-focus": "8.8.0",
"@fluentui/theme": "2.6.12"
},
"@uifabric/styling": {
"@fluentui/theme": "1.7.7"
}
}
You might need to add another packages to this list. Just check build log for the failing package. Then go to its version list and find one that was released before yesterday.
thanks @Front-start I have pasted the following packages as dependencies in package.json file, and it worked.
thanks again !!
"@fluentui/react-hooks": "8.6.7",
"@fluentui/style-utilities": "8.7.7",
"@fluentui/foundation-legacy": "8.2.15",
"@fluentui/font-icons-mdl2": "8.4.8",
"@fluentui/react-focus": "8.8.0",
"@fluentui/theme": "2.6.12"
thanks @Front-start I have pasted the following packages as dependencies in package.json file, and not getting the error.
"@fluentui/react-hooks": "8.6.7", "@fluentui/style-utilities": "8.7.7", "@fluentui/foundation-legacy": "8.2.15", "@fluentui/font-icons-mdl2": "8.4.8", "@fluentui/react-focus": "8.8.0", "@fluentui/theme": "2.6.12"
Hey, I did as you suggested, but I'm working with yarn workspaces, and it didn't help me, so I had to downgrade to fluent version 7. if someone knows how I can solve it, ill be more then grateful