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.

MUI: The `value` provided to the Tabs component is invalid....

See original GitHub issue

Duplicates

  • I have searched the existing issues

Latest version

  • I have tested the latest version

Current behavior 😯

When using the tabs component I get,

Tabs.js:366 MUI: The value provided to the Tabs component is invalid. The Tab with this value (“0”) is not part of the document layout. Make sure the tab item is present in the document or that it’s not display: none.

This occurs both in my own code, and when I copy examples from https://mui.com/material-ui/react-tabs/#experimental-api

There is some stack overflow questions but no solutions https://stackoverflow.com/questions/72085892/mui-the-value-provided-to-the-tabs-component-is-invalid-the-tab-with-this-v https://stackoverflow.com/questions/71613867/mui-nested-tabs-error-the-value-provided-to-the-tabs-component-is-invalid

Expected behavior 🤔

No response

Steps to reproduce 🕹

Steps:

Context 🔦

No response

Your environment 🌎

`npx @mui/envinfo`
  Don't forget to mention which browser you used.
  Output from `npx @mui/envinfo` goes here.

Issue Analytics

  • State:closed
  • Created a year ago
  • Reactions:4
  • Comments:42 (3 by maintainers)

github_iconTop GitHub Comments

11reactions
skrimussscommented, Sep 26, 2022

you need to: <Tabs —> value={false} <— />

9reactions
samislamcommented, Oct 22, 2022

I have tried everything, approximately 46 hours trying to figure out a workaround for this error. But no-way. It’s obviously a bug. And it has to be fixed. And for the people who were able to find some workarounds for their projects. Congratulations. But for me, I’ll have to wait for the next update until one of the maintainers commit a patch release for this particular bug, which is the only one I was able to catch during my project which I was working on (for 9 months). Mui is a great library. And this is the only bug I was able to find in “@mui/material”. Some other bugs I encountered in “@mui/x-data-grid”. But let’s forget about that now.

I was able to complete my entire project peacefully, the only part left for me is this error. But it’s okay for now, the project still can survive with that.

image image image image

Read more comments on GitHub >

github_iconTop Results From Across the Web

index.js:1375 Warning: Material-UI: the value provided `/` to ...
The error message is telling you that the value on Tabs (via VerticalTabs) does not match any of the values on your individual...
Read more >
MUI: The `value` provided to the Tabs component is invalid ...
[Solved]-MUI: The `value` provided to the Tabs component is invalid. The Tab with this `value` ("0") is not part of the document layout-Reactjs....
Read more >
React Tabs component - Material UI - MUI
<Box sx={{ borderBottom: 1, borderColor: 'divider' }}> <Tabs value={value} onChange={handleChange} aria-label="basic tabs example"> <Tab label="Item One" {.
Read more >
Material-Ui: The Value Provided '/' To The Tabs Component Is ...
Index.Js:1375 Warning: Material-Ui: The Value Provided '/' To The Tabs Component Is Invalid. None Of The Tabs Children ...
Read more >
How to integrate Material-UI's Tabs with react router?
This is happening because the Tabs component expects a value prop whose value must match one of the underlying Tab 's values. But...
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