UNPKG

falcor-router

Version:

A router DataSource constructor for falcor that allows you to model all your cloud data sources as a single JSON resource.

14 lines (11 loc) 301 B
module.exports = function copy(valueType) { if ((typeof valueType !== 'object') || (valueType === null)) { return valueType; } return Object. keys(valueType). reduce(function(acc, k) { acc[k] = valueType[k]; return acc; }, {}); };