List of questions
Related questions
Question 90 - Certified JavaScript Developer I discussion
Which code statement below correctly persists an objects in local Storage ?
A.
const setLocalStorage = (storageKey, jsObject) => {window.localStorage.setItem(storageKey, JSON.stringify(jsObject));}
B.
const setLocalStorage = ( jsObject) => {window.localStorage.connectObject(jsObject));}
C.
const setLocalStorage = ( jsObject) => {window.localStorage.setItem(jsObject);}
D.
const setLocalStorage = (storageKey, jsObject) => {window.localStorage.persist(storageKey, jsObject);}
Your answer:
0 comments
Sorted by
Leave a comment first