Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/llh1/DataSearch

Blazing fast full text search in Javascript
https://github.com/llh1/DataSearch

Last synced: 11 days ago
JSON representation

Blazing fast full text search in Javascript

Awesome Lists containing this project

README

        

# DataSearch.js
Blazing fast full text search in Javascript

[![Build Status](https://travis-ci.org/llh1/DataSearch.svg?branch=master)](https://travis-ci.org/llh1/DataSearch)

DataSearch.js is an attempt to use the power of regular expression to search across the keys of a Javascript hash.

## Quick Start

```javascript
var DataSearch = require('datasearch');

var data = [
{name: {firstName: "Iron", lastName: "Man"}, country: "United States"},
{name: {firstName: "Sherlock", lastName: "Holmes"}, country: "United Kingdom"},
{name: {firstName: "Bruce", lastName: "Lee"}, country: "China"}
];

var dataSearch = new DataSearch(data);
dataSearch.search("iron states"); // => {name: {firstName: "Iron", lastName: "Man"}, country: "United States"}
```