JavaScript: Create/Delete Property

By Xah Lee. Date: . Last updated: .

Create Property When Object is Created

Properties can be created at the same time when you create a object. There are 2 ways:

Add Property

New properties can be added to a existing object. If the property already exist, it's modified. Here's the ways:

Delete Property

JavaScript Property

JavaScript in Depth