javascript - Extract Variable from jQuery object -
this question has answer here:
i have single object returns following:
{left: "642px", top: "305px", opacity: "1"}
i trying break these out 3 separate variables: var left
, var top
, , var opacity
what simplest way go this?
use:
var data = {left: "642px", top: "305px", opacity: "1"}; var left = data.left, top = data.top, opacity = data.opacity;