JSFiddle - React, Tailwind, and code Playground
HTML
<script src="http://defiantjs.com/defiant.js/dist/defiant-latest.min.js"></script>
JavaScript
var data = {
"store": {
"book": [
{
"title": "Sword of Honour",
"category": "fiction",
"author": "Evelyn Waugh",
"@price": 12.99
},
{
"title": "Moby Dick",
"category": "fiction",
"author": "Herman Melville",
"isbn": "0-553-21311-3",
"@price": 8.99
},
{
"title": "Sayings of the Century",
"category": "reference",
"author": "Nigel Rees",
"@price": 8.95
},
{
"title": "The Lord of the Rings",
"category": "fiction",
"author": "J. R. R. Tolkien",
"isbn": "0-395-19395-8",
"@price": 22.99
}
],
"bicycle": {
"brand": "Cannondale",
"color": "red",
"@price": 19.95
}
}
},
found = JSON.search(data, "//*[contains(translate(title, 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'abcdefghijklmnopqrstuvwxyz'), 'r')]");
console.log( found[0].author );
// 'J. R. R. Tolkien'