-
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
createContext is not a function #3458
Comments
It was a version conflict, everything is working great. Thanks for creating it. |
Which version conflict? I'm seeing this error while using React v15.6.2. I found some issues about that error showing up if you're not using React v16.3+. Was that the case for you? |
I don't have the exact version I was on at the moment, but it was the low 16.x.x and when I came up to head revision, the problem went away. Hope this helps. |
@Mottie did you find a solution to the conflict with v15.6.2. I'm using v15.6.2 and it's giving me the same error. I have other packages that are in conflict with React v16+, so I can't upgrade at the moment. |
IIRC, it was because react-bootstrap was updated. When we switched to |
I am getting this issue as well. My project was working ok until I did:
Based on other articles, I also tried:
However, I am still getting this error:
npm show react version npm show react-bootstrap version & npm view react-bootstrap version |
Hey @mhectorgato , I seem to be having the exact same error. Did you find a solution? |
No never did |
whats the fix for this as we are getting the same error after updating bootstrap to v4. "react": "15.3.2" |
I was doing this for a .NET Core app, and the trick for me was to be in the "ClientApp" directory instead of the src directory. Then I ran That fixed it. Versions for reference: |
thanks for coming back. trying that now... |
oh boy - a stack of peer dependency errors and fails to compile. wondering if anyone else encountered similar?. Im assuming at this stage ill have to do a manual install of all of these dependencies |
You need React 16.x. We no longer support 15.x. |
thanks @taion we are now on 16.8. now we have this: ERROR in ./~/react-addons-css-transition-group/index.js Module not found: Error: Can't resolve 'react/lib/ReactCSSTransitionGroup' in... trying to resolve but there is no folder called LIB under REACT is the index.js pointing to the correct place or am I missing something else? |
Thanks man you save my life :D |
Bootcamp student here working on an electron app and bootstrap for the first time. This worked, thanks for saving my butt! |
I have just added react-bootstrap to a prototype project and get the below error. If I remove the Import and the Navbar block and rebuild, everything works as before without any changes to webpack config.
I am new to a number of the technologies here and am sure its something I have not set correctly, but any help in pointing me in the right direction would be appreciated.
Thanks
…
...
import { Navbar, Nav, NavDropdown, Form, FormControl, Button } from "react-bootstrap";
..
..
<Navbar.Brand href="#home">Paycheck Planner</Navbar.Brand>
<Navbar.Toggle aria-controls="basic-navbar-nav" />
Uncaught TypeError: react__WEBPACK_IMPORTED_MODULE_3___default.a.createContext is not a function
at eval (ThemeProvider.js:15)
at Object../node_modules/react-bootstrap/es/ThemeProvider.js (bundle.js:3459)
at webpack_require (bundle.js:20)
at eval (createWithBsPrefix.js:12)
at Object../node_modules/react-bootstrap/es/utils/createWithBsPrefix.js (bundle.js:3555)
at webpack_require (bundle.js:20)
at eval (Alert.js:12)
at Object../node_modules/react-bootstrap/es/Alert.js (bundle.js:2499)
at webpack_require (bundle.js:20)
at eval (index.js:2)
The text was updated successfully, but these errors were encountered: