// edit search and paste me into your browser console search = 'my cool search'; // this will only work for the spaces you have cached // i.e. you've opened the space on this device recently spaces = Object.keys(localStorage); spaces = spaces.filter(space => space.startsWith('space-')); spaces = spaces.map(space => JSON.parse(localStorage[space])); matchingSpaces = spaces.filter(space => { if (!space.name) { return }; return space.name.toLowerCase().includes(search.toLowerCase()); }); console.log('🌌 matching spaces', matchingSpaces); matchingCards = [] spaces.forEach(space => { if (!space.cards) { return } return space.cards.filter(card => { if (!card.name) { return }; if (card.name.toLowerCase().includes(search.toLowerCase())) { match = { cardId: card.id, position: { x: card.x, y: card.y }, name: card.name, space: space.name } matchingCards.push(match); } }) }); console.log('🍄 matching cards', matchingCards);