Skip to content

react integration #15

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

Open
MihaMarkic opened this issue Dec 1, 2016 · 7 comments
Open

react integration #15

MihaMarkic opened this issue Dec 1, 2016 · 7 comments
Labels

Comments

@MihaMarkic
Copy link

Is there a react integration somewhere?

@mdehoog
Copy link
Owner

mdehoog commented Dec 1, 2016

This issue may be of interest: Semantic-Org/Semantic-UI-React#908

@MihaMarkic
Copy link
Author

So, basically there isn't, but it is doable manually and it drags jquery along. Would that be correct?

@mdehoog
Copy link
Owner

mdehoog commented Dec 2, 2016

Yes, correct 😀

@ankitrg
Copy link

ankitrg commented Dec 16, 2016

How can I use it via NPM?
I installed the package and now when I do import:

import { calendar } from 'semantic-ui-calendar/dist/calendar.min.js';
import 'semantic-ui-calendar/dist/calendar.min.css';

I get error like this:

calendar.min.js:1 Uncaught ReferenceError: jQuery is not defined(…)

Is there a way I can fix this?

@harel
Copy link

harel commented Dec 18, 2016

@ankitrg if you're using webpack, you can add jquery as a plugin. Something like:

     new webpack.ProvidePlugin({
			'$': 'jquery',
			'jQuery': 'jquery',
			'React': 'react'
		}),

@ankitrg
Copy link

ankitrg commented Dec 19, 2016

@harel Actually I am using create_react_app and webpack file is not available directly. I want to use it without ejecting, is there a way?

@harel
Copy link

harel commented Jan 7, 2017

Sorry for the delay - I'm not sure. I've started my app before create_react_app and I've had to manually configure all of this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants