Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@redis/search

Package Overview
Dependencies
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@redis/search - npm Package Compare versions

Comparing version 1.1.3 to 1.1.4

dist/commands/SEARCH_NOCONTENT.d.ts

4

dist/commands/AGGREGATE.js

@@ -13,3 +13,3 @@ "use strict";

AggregateSteps["FILTER"] = "FILTER";
})(AggregateSteps = exports.AggregateSteps || (exports.AggregateSteps = {}));
})(AggregateSteps || (exports.AggregateSteps = AggregateSteps = {}));
var AggregateGroupByReducers;

@@ -30,3 +30,3 @@ (function (AggregateGroupByReducers) {

AggregateGroupByReducers["RANDOM_SAMPLE"] = "RANDOM_SAMPLE";
})(AggregateGroupByReducers = exports.AggregateGroupByReducers || (exports.AggregateGroupByReducers = {}));
})(AggregateGroupByReducers || (exports.AggregateGroupByReducers = AggregateGroupByReducers = {}));
exports.FIRST_KEY_INDEX = 1;

@@ -33,0 +33,0 @@ exports.IS_READ_ONLY = true;

@@ -23,2 +23,3 @@ import * as _LIST from './_LIST';

import * as SEARCH from './SEARCH';
import * as SEARCH_NOCONTENT from './SEARCH_NOCONTENT';
import * as SPELLCHECK from './SPELLCHECK';

@@ -82,2 +83,4 @@ import * as SUGADD from './SUGADD';

search: typeof SEARCH;
SEARCH_NOCONTENT: typeof SEARCH_NOCONTENT;
searchNoContent: typeof SEARCH_NOCONTENT;
SPELLCHECK: typeof SPELLCHECK;

@@ -84,0 +87,0 @@ spellCheck: typeof SPELLCHECK;

@@ -26,2 +26,3 @@ "use strict";

const SEARCH = require("./SEARCH");
const SEARCH_NOCONTENT = require("./SEARCH_NOCONTENT");
const SPELLCHECK = require("./SPELLCHECK");

@@ -84,2 +85,4 @@ const SUGADD = require("./SUGADD");

search: SEARCH,
SEARCH_NOCONTENT,
searchNoContent: SEARCH_NOCONTENT,
SPELLCHECK,

@@ -135,3 +138,3 @@ spellCheck: SPELLCHECK,

RedisSearchLanguages["CHINESE"] = "Chinese";
})(RedisSearchLanguages = exports.RedisSearchLanguages || (exports.RedisSearchLanguages = {}));
})(RedisSearchLanguages || (exports.RedisSearchLanguages = RedisSearchLanguages = {}));
function pushSortByProperty(args, sortBy) {

@@ -178,3 +181,3 @@ if (typeof sortBy === 'string') {

SchemaFieldTypes["VECTOR"] = "VECTOR";
})(SchemaFieldTypes = exports.SchemaFieldTypes || (exports.SchemaFieldTypes = {}));
})(SchemaFieldTypes || (exports.SchemaFieldTypes = SchemaFieldTypes = {}));
var SchemaTextFieldPhonetics;

@@ -186,3 +189,3 @@ (function (SchemaTextFieldPhonetics) {

SchemaTextFieldPhonetics["DM_ES"] = "dm:es";
})(SchemaTextFieldPhonetics = exports.SchemaTextFieldPhonetics || (exports.SchemaTextFieldPhonetics = {}));
})(SchemaTextFieldPhonetics || (exports.SchemaTextFieldPhonetics = SchemaTextFieldPhonetics = {}));
var VectorAlgorithms;

@@ -192,3 +195,3 @@ (function (VectorAlgorithms) {

VectorAlgorithms["HNSW"] = "HNSW";
})(VectorAlgorithms = exports.VectorAlgorithms || (exports.VectorAlgorithms = {}));
})(VectorAlgorithms || (exports.VectorAlgorithms = VectorAlgorithms = {}));
function pushSchema(args, schema) {

@@ -195,0 +198,0 @@ for (const [field, fieldOptions] of Object.entries(schema)) {

{
"name": "@redis/search",
"version": "1.1.3",
"version": "1.1.4",
"license": "MIT",

@@ -21,9 +21,9 @@ "main": "./dist/index.js",

"@redis/test-utils": "*",
"@types/node": "^20.2.3",
"@types/node": "^20.6.2",
"nyc": "^15.1.0",
"release-it": "^15.10.3",
"release-it": "^16.1.5",
"source-map-support": "^0.5.21",
"ts-node": "^10.9.1",
"typedoc": "^0.24.7",
"typescript": "^5.0.4"
"typedoc": "^0.25.1",
"typescript": "^5.2.2"
},

@@ -30,0 +30,0 @@ "repository": {

@@ -15,3 +15,3 @@ # @redis/search

Before we can perform any searches, we need to tell RediSearch how to index our data, and which Redis keys to find that data in. The [FT.CREATE](https://oss.redis.com/redisearch/Commands/#ftcreate) command creates a RediSearch index. Here's how to use it to create an index we'll call `idx:animals` where we want to index hashes containing `name`, `species` and `age` fields, and whose key names in Redis begin with the prefix `noderedis:animals`:
Before we can perform any searches, we need to tell RediSearch how to index our data, and which Redis keys to find that data in. The [FT.CREATE](https://redis.io/commands/ft.create) command creates a RediSearch index. Here's how to use it to create an index we'll call `idx:animals` where we want to index hashes containing `name`, `species` and `age` fields, and whose key names in Redis begin with the prefix `noderedis:animals`:

@@ -32,7 +32,7 @@ ```javascript

See the [`FT.CREATE` documentation](https://oss.redis.com/redisearch/Commands/#ftcreate) for information about the different field types and additional options.
See the [`FT.CREATE` documentation](https://redis.io/commands/ft.create/#description) for information about the different field types and additional options.
#### Querying the Index
Once we've created an index, and added some data to Redis hashes whose keys begin with the prefix `noderedis:animals`, we can start writing some search queries. RediSearch supports a rich query syntax for full-text search, faceted search, aggregation and more. Check out the [`FT.SEARCH` documentation](https://oss.redis.com/redisearch/Commands/#ftsearch) and the [query syntax reference](https://oss.redis.com/redisearch/Query_Syntax/) for more information.
Once we've created an index, and added some data to Redis hashes whose keys begin with the prefix `noderedis:animals`, we can start writing some search queries. RediSearch supports a rich query syntax for full-text search, faceted search, aggregation and more. Check out the [`FT.SEARCH` documentation](https://redis.io/commands/ft.search) and the [query syntax reference](https://redis.io/docs/interact/search-and-query/query) for more information.

@@ -117,3 +117,3 @@ Let's write a query to find all the animals where the `species` field has the value `dog`:

We'll use the [RediSearch query language](https://oss.redis.com/redisearch/Query_Syntax/) and [`FT.SEARCH`](https://oss.redis.com/redisearch/Commands/#ftsearch) command. Here's a query to find users under the age of 30:
We'll use the [RediSearch query language](https://redis.io/docs/interact/search-and-query/query) and [`FT.SEARCH`](https://redis.io/commands/ft.search) command. Here's a query to find users under the age of 30:

@@ -120,0 +120,0 @@ ```javascript

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc