hussain
hussain

Reputation: 7083

How to remove element from array using angularjs?

Once i rendered data from backend i want to remove element id from the array how can i achieve that using angularjs ?

ctrl.js

$scope.array =  [{
        "name": "Java Class",
        "id": "javaClass",
        "createdBy": "shu",
        "__v": 0,
        "properties": [{
            "label": "Java Package Name",
            "type": "String",
            "editable": true,
            "binding": {
                "type": "property",
                "name": "camunda:class"
            }
        }],
        "appliesTo": ["bpmn:ServiceTask"]
    }]

Upvotes: 0

Views: 1765

Answers (1)

guest271314
guest271314

Reputation: 1

You can use delete

delete $scope.array[0].id;

Upvotes: 2

Related Questions