JSFiddle - React, Tailwind, and code Playground

by Hui Zheng

HTML

<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8"/>
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
    <meta name="description" content="Tizen example"/>
    <title>Tizen lodash.js example</title>
</head>
<body>
<div id="first">
</div>
<br>
<div id="second">
</div>

</body>

</html>

JavaScript

var firstDiv = document.getElementById('first');
    var secondDiv = document.getElementById('second');

    var firstValue = { 'grapes':20, 'oranges':15, 'limons':12 };

  firstDiv.innerHTML = "Having the object with key value pairs:<br><br>";

  firstDiv.innerHTML += JSON.stringify(firstValue);
alert(_.mapKeys);
    var result = _.mapKeys(firstValue, function(value, key) {
        return "new_"+key;
    });
alert("here!");
  //secondDiv.innerHTML = "...we map the existing key names and we get:<br><br>";

  firstDiv.innerHTML += JSON.stringify(result);