English 中文(简体)
Underscore.JS - Updating Objects
  • 时间:2024-09-17

Underscore.JS - Updating Objects


Previous Page Next Page  

Underscore.JS has many easy to use methods which helps in updating objects. This chapter discusses them in detail.

Underscore.JS provides various methods to handle object updates as psted below −

Sr.No. Method & Syntax
1 extend

_.extend(destination, *sources)

2 pick

_.pick(object, *keys)

3 omit

_.omit(object, *keys)

4 defaults

_.defaults(object, *defaults)

5 clone

_.clone(object)

6 tap

_.tap(object, interceptor)

7 has

_.has(object, key)

8 property

_.property(path)

9 propertyOf

_.propertyOf(object)

Advertisements