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

elastic-builder

Package Overview
Dependencies
Maintainers
0
Versions
77
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

elastic-builder - npm Package Compare versions

Comparing version 2.29.0 to 2.30.0

5

package.json
{
"name": "elastic-builder",
"version": "2.29.0",
"version": "2.30.0",
"description": "A JavaScript implementation of the elasticsearch Query DSL",

@@ -110,4 +110,5 @@ "main": "src/index.js",

"sandeep952 <sandy335582@gmail.com>",
"florian-lackner365 <florian.lackner@365talents.com>"
"florian-lackner365 <florian.lackner@365talents.com>",
"Alejandro Marulanda <alejokf@gmail.com>"
]
}

33

src/core/runtime-field.js

@@ -49,3 +49,3 @@ 'use strict';

* @param {string} script
* @returns {void}
* @returns {RuntimeField} returns `this` so that calls can be chained.
*/

@@ -57,2 +57,3 @@ script(script) {

this._isScriptSet = true;
return this;
}

@@ -63,3 +64,3 @@

* @param {string} type One of `boolean`, `composite`, `date`, `double`, `geo_point`, `ip`, `keyword`, `long`, `lookup`.
* @returns {void}
* @returns {RuntimeField} returns `this` so that calls can be chained.
*/

@@ -73,5 +74,33 @@ type(type) {

this._isTypeSet = true;
return this;
}
/**
* Specifies the language the script is written in. Defaults to `painless` but
* may be set to any of languages listed in [Scripting](https://www.elastic.co/guide/en/elasticsearch/reference/current/modules-scripting.html).
*
* @param {string} lang The language for the script.
* @returns {RuntimeField} returns `this` so that calls can be chained.
*/
lang(lang) {
if (!isNil(this._body.script)) {
this._body.script.lang = lang;
}
return this;
}
/**
* Specifies any named parameters that are passed into the script as variables.
*
* @param {Object} params Named parameters to be passed to script.
* @returns {RuntimeField} returns `this` so that calls can be chained.
*/
params(params) {
if (!isNil(this._body.script)) {
this._body.script.params = params;
}
return this;
}
/**
* Override default `toJSON` to return DSL representation for the `script`.

@@ -78,0 +107,0 @@ *

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