pelias-query
Advanced tools
Comparing version 8.2.0 to 8.3.0
@@ -6,2 +6,3 @@ { | ||
"centroid:field": "center_point", | ||
"categories:field": "category", | ||
@@ -8,0 +9,0 @@ "sort:distance:order": "asc", |
@@ -22,2 +22,3 @@ | ||
multi_match: require('./view/multi_match'), | ||
categories: require('./view/categories'), | ||
boundary_circle: require('./view/boundary_circle'), | ||
@@ -24,0 +25,0 @@ boundary_rect: require('./view/boundary_rect'), |
/** | ||
A primitive Javascript variable wrapped in an Object so that it can be | ||
handled by reference instead of by value. | ||
A primitive Javascript variable wrapped in an Object so that it can be | ||
handled by reference instead of by value. | ||
This is useful as an inline variable placeholder where the value may or | ||
may not be known when the query is constructed. | ||
This is useful as an inline variable placeholder where the value may or | ||
may not be known when the query is constructed. | ||
note: values must be a valid js primitive type (string,numeric,boolean), | ||
or an Array. No objects allowed. | ||
note: the object prototype contains custom serialization methods | ||
note: values must be a valid js primitive type (string,numeric,boolean), | ||
or an Array. No objects allowed. | ||
note: the object prototype contains custom serialization methods | ||
warning: using an instance of Variable() in a boolean operation will | ||
*always* yield true; regardless of the underlying value; because js. | ||
**/ | ||
warning: using an instance of Variable() in a boolean operation will | ||
*always* yield true; regardless of the underlying value; because js. | ||
**/ | ||
@@ -37,2 +37,2 @@ var check = require('check-types'); | ||
module.exports = Variable; | ||
module.exports = Variable; |
{ | ||
"name": "pelias-query", | ||
"version": "8.3.0", | ||
"description": "An Elasticsearch query builder for Pelias", | ||
"main": "index.js", | ||
"version": "8.2.0", | ||
"scripts": { | ||
@@ -7,0 +7,0 @@ "lint": "jshint .", |
@@ -143,2 +143,4 @@ >This repository is part of the [Pelias](https://github.com/pelias/pelias) | ||
input:categories: "food,education" | ||
boundary:circle:lat: 1 | ||
@@ -145,0 +147,0 @@ boundary:circle:lon: 2 |
@@ -60,4 +60,7 @@ | ||
v.set(false); | ||
t.equal(v.$, false, 'bolean'); | ||
t.equal(v.$, false, 'boolean'); | ||
v.set([1, 2, 3]); | ||
t.isEquivalent(v.$, [1, 2, 3], 'array'); | ||
v.set(['a', 'b']); | ||
@@ -107,2 +110,8 @@ t.deepEqual(v.$, ['a', 'b'], 'array'); | ||
}); | ||
test('toString: array', function(t) { | ||
var v = new Variable(); | ||
v.set([1, 2, 3]); | ||
t.equal(''+v.toString(), '1,2,3', 'array'); | ||
t.end(); | ||
}); | ||
}; | ||
@@ -123,2 +132,8 @@ | ||
}); | ||
test('toJSON: array', function(t) { | ||
var v = new Variable(); | ||
v.set([1, 2, 3]); | ||
t.equal(JSON.stringify({ test: v }), '{"test":[1,2,3]}', 'array'); | ||
t.end(); | ||
}); | ||
}; | ||
@@ -125,0 +140,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
149509
60
3922
522