Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to delete an object from memory using jQuery/Javascript? [duplicate]

I am creating an application in which I have a page for creating a customer. for that I have written following code.

customer=new MobileApp.CustomerViewModel(); //for creating new customer

I want to delete this object. how can I perform this ??

like image 422
Rudresh Bhatt Avatar asked Nov 30 '22 21:11

Rudresh Bhatt


1 Answers

Setting customer = null will make this enable for garbage collector, given that there is no other valid reference to that object.

like image 70
taskinoor Avatar answered Dec 03 '22 09:12

taskinoor