Skip to content

Instantly share code, notes, and snippets.

💭
🚀

Mike Mathew m2mathew

💭
🚀
Block or report user

Report or block m2mathew

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@gaearon
gaearon / slim-redux.js
Last active Jun 13, 2019
Redux without the sanity checks in a single file. Don't use this, use normal Redux. :-)
View slim-redux.js
function mapValues(obj, fn) {
return Object.keys(obj).reduce((result, key) => {
result[key] = fn(obj[key], key);
return result;
}, {});
}
function pick(obj, fn) {
return Object.keys(obj).reduce((result, key) => {
if (fn(obj[key])) {
You can’t perform that action at this time.