Socket
Socket
Sign inDemoInstall

minisearch

Package Overview
Dependencies
Maintainers
1
Versions
81
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

minisearch - npm Package Compare versions

Comparing version 6.0.1 to 6.1.0

8

CHANGELOG.md

@@ -5,2 +5,10 @@ # Changelog

# v6.1.0
- Add `getStoredFields` method to retrieve the stored fields for a document
given its ID.
- Pass stored fields to the `boostDocument` callback function, making it
easier to perform dynamic document boosting.
# v6.0.1

@@ -7,0 +15,0 @@

2

dist/es/SearchableMap.js

@@ -15,3 +15,5 @@ /******************************************************************************

***************************************************************************** */
/* global Reflect, Promise */
function __values(o) {

@@ -18,0 +20,0 @@ var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;

@@ -15,3 +15,5 @@ /******************************************************************************

***************************************************************************** */
/* global Reflect, Promise */
function __values(o) {

@@ -18,0 +20,0 @@ var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;

@@ -286,5 +286,8 @@ type LeafType = '' & {

* the document ID, and a term that matches the search in that document, and
* should return a boosting factor.
* the value of the stored fields for the document (if any). It should return
* a boosting factor: a number higher than 1 increases the computed score, a
* number lower than 1 decreases the score, and a falsy value skips the search
* result completely.
*/
boostDocument?: (documentId: any, term: string) => number;
boostDocument?: (documentId: any, term: string, storedFields?: Record<string, unknown>) => number;
/**

@@ -916,2 +919,10 @@ * Controls whether to perform prefix search. It can be a simple boolean, or a

/**
* Returns the stored fields (as configured in [[Options.storeFields]]) for
* the given document ID. Returns `undefined` if the document is not present
* in the index.
*
* @param id The document ID
*/
getStoredFields(id: any): Record<string, unknown> | undefined;
/**
* Search for documents matching the given search query.

@@ -918,0 +929,0 @@ *

@@ -21,3 +21,5 @@ (function (global, factory) {

***************************************************************************** */
/* global Reflect, Promise */
function __values(o) {

@@ -24,0 +26,0 @@ var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;

2

package.json
{
"name": "minisearch",
"version": "6.0.1",
"version": "6.1.0",
"description": "Tiny but powerful full-text search engine for browser and Node",

@@ -5,0 +5,0 @@ "main": "dist/umd/index.js",

@@ -88,3 +88,3 @@ # MiniSearch

```html
<script src="https://cdn.jsdelivr.net/npm/minisearch@6.0.1/dist/umd/index.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/minisearch@6.1.0/dist/umd/index.min.js"></script>
```

@@ -91,0 +91,0 @@

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

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