Skip to content

Latest commit

 

History

History
38 lines (21 loc) · 905 Bytes

File metadata and controls

38 lines (21 loc) · 905 Bytes

JavaScript Objects Lab

Overview

In this lab, we'll create objects and perform various operations on them.

Instructions

Be sure to run the tests to get a feel for the types of problems this lab is asking you to solve. In particular, you'll need to define a recipes object and then apply certain updates (destructively and non-destructively) in various functions.

recipes

Good luck!

HINT: You might find deleteFromObjectByKey to be a bit hard to write non-destructively. Think about how we learned to use Object.assign. What happens if we do

var obj = { fot: 'bar' }

var newObj = Object.assign({}, obj)

newObj // { fot: 'bar' }

delete newObj.fot // true

newObj // {}

obj // { fot: 'bar' }

Resources