Question related to Object.extendsObject()

alisha4
Kilo Explorer

HI ALL,

I have gone through the prototype js docs.,but there is no function "extendObject()" defined for Object.

Object.extendsObject();

Please tell me.

7 REPLIES 7

Chris M3
Tera Guru

I believe that this is a custom Service-now function that they added to the base Javascript 'Object'.   It behaves slightly different then Prototypes extend (and summarily breaks some things).   For example, if the object you are extending has a 'name' property, it does not work in the extended object.


is it documented any where


Hi Alakhya,



Its a wrapper method to prototypeJS Class.create



Open console and type object.extendObject in any servicenow opened window.



You will see function definition



function () {


return Class.create.apply(null, arguments).prototype;


}


Can you please tell where i can see in the console.


I checked but i did not find