@nozbe/watermelondb
Version:
Build powerful React Native and React web apps that scale from hundreds to tens of thousands of records and remain fast
21 lines (19 loc) • 415 B
JavaScript
;
exports.__esModule = true;
exports.default = toPairs;
// inspired by ramda and rambda
/* eslint-disable */
function toPairs(obj) {
var pairs = [];
if (obj) {
var keys = Object.keys(obj);
for (var i = 0, len = keys.length; i < len; i++) {
var prop = keys[i];
var value = obj[prop];
if (prop in obj) {
pairs[i] = [prop, value];
}
}
}
return pairs;
}