-
-
Notifications
You must be signed in to change notification settings - Fork 298
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
switch to matchmedia module for client/server abstraction #11
Conversation
|
||
var defaultTypes = { | ||
component: React.PropTypes.func, | ||
query: React.PropTypes.string | ||
query: React.PropTypes.string, | ||
values: React.PropTypes.object |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you define the shape of this object with React.PropTypes.shape? also need docs on this new prop
lgtm just need more info on the new prop then 👍 |
I think I got everything. Diff is large because I rebuilt the samples to add the static sample. |
I removed the rebuilding of dists |
```js | ||
var mq = require('react-responsive'); | ||
```jsx | ||
var Mq = require('react-responsive'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
MQ? MediaQuery?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I dig MediaQuery, will update
Updated |
switch to matchmedia module for client/server abstraction
Thanks! Owe you a 🍻 |
I was able to keep this PR much smaller than anticipated due to the
matchmedia
modules abstraction for client/server. It just takes an optional 2nd parameter,values
, that it uses ifwindow.matchMedia
can't be accessed.