-
Notifications
You must be signed in to change notification settings - Fork 201
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
jQuery? #12
Comments
It would be nice to do a proper port of this library. For now, it's just a very dumb wrapper around the original library- not an actual port to react. I did it because it fit a need for a project I was working on (and I decided to publish it for other people to use if they wanted). We were already using jQuery (due to bootstrap), but now that I read the react-bootstrap docs, jQuery is only required for ie8 support. It would be nice to remove the jQuery dependency, but that would mean actually porting/fixing all the code in the original library: https://github.com/skratchdot/react-bootstrap-daterangepicker/blob/master/lib/daterangepicker.js Right now I periodically update that file w/ the upstream code, so it'd be a maintenance issue as well. I'll leave this open though in case anyone feels like doing this... |
I hear you bro, that jQ datepicker has been around for a while, and must be pretty solid by now. It would suck to reimplement this thing.... hmm this is the javascript world though lol. Thanks for the response. |
hmmmm anyone tried this with Zepto instead? |
I haven't tested that yet. It should just require changing these 2 lines:
I'd have to think about how to make that configurable. I could leave out the hard require statements I have in index.js, and then React, jQuery, etc could be included by the end-user. That would work well in a browser environment, but my original usage of this lib was in a build environment that used browserify, so it made sense to use npm style require statements in the index.js file. Also, changing the upstream daterangepicker.js file would be more tricky since I have a script that automatically updates that file: |
I was saddened by this when I did the NPM install and automatically made it a no go. Any way to get this kind of functionality without jQ anyone do a react only fork of this? I know this is just a port of the old jQ plugin, so I guess that may be asking for a lot, but it doesn't seem worth importing jQ for just this when I already have react, react-router, and react-bootstrap weighing me down.
Either way, thanks for your hard work, wish I could actually use this.
The text was updated successfully, but these errors were encountered: