-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
expected a string (for built-in components) or a class/function (for composite components) but got: undefined on Navbar #6701
Comments
@daxnet const App = () => { export default App |
import Container from 'react-bootstrap/Container'; function Home() { <Nav.Link href="#home">Home</Nav.Link> <Nav.Link href="#link">Link</Nav.Link> <NavDropdown.Item href="#action/3.1">Action</NavDropdown.Item> <NavDropdown.Item href="#action/3.2"> Another action </NavDropdown.Item> <NavDropdown.Item href="#action/3.3">Something</NavDropdown.Item> <NavDropdown.Divider /> <NavDropdown.Item href="#action/3.4"> Separated link </NavDropdown.Item> </Navbar.Collapse> ); } export default Home |
Dupe of #6669 |
Prerequisites
Describe the bug
Just copied the example from documentation but still get the following error:
Nodejs: 18.18.0
Create new React project with Nextjs:
Install react bootstrap:
Then, in the
page.tsx
file, paste the following:Run the app:
Then navigate to http://localhost:3000
Error:
Note that other components like Button, Badge, etc. workes just fine.
Expected behavior
Navbar should work normally without any error.
To Reproduce
No response
Reproducible Example
no
Screenshots
No response
What operating system(s) are you seeing the problem on?
No response
What browser(s) are you seeing the problem on?
No response
What version of React-Bootstrap are you using?
2.9.0
What version of Bootstrap are you using?
5.3.2
Additional context
No response
The text was updated successfully, but these errors were encountered: