split :js-value into :js-array and :js-object