Javascript code to store a value to session storafe code example
Example: javascript sessionStorage
var setsession = window.sessionStorage.setItem("animals", "cat");
var getsession = window.sessionStorage.getItem("animals");
console.log(getsession);