"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=function(r,e,t){if(!r)return t;var s,i;if(Array.isArray(e)&&(s=e.slice(0)),"string"==typeof e&&(s=e.split(".")),"symbol"==typeof e&&(s=[e]),!Array.isArray(s))throw new Error("props arg must be an array, a string or a symbol");for(;s.length;){if(i=s.shift(),!r)return t;if(void 0===(r=r[i]))return t}return r};