importSafe,{unwrap}from'sfobj'// const { Safe, unwrap } = require('sfobj')constobj=Safe({hello: 'world'})console.log(obj.hello[unwrap])// Output: worldconsole.log(obj.this.prop[0].does.not().even.exist()[unwrap])// Output: undefined// No more null/undefined checksif(typeofobj.a.b().c[1].d()[unwrap]==='number'){// do something here}// Easier to set default valueconstname=obj.getUsers().list[0].name[unwrap]||''