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

jsexp

Package Overview
Dependencies
Maintainers
4
Versions
20
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

jsexp - npm Package Compare versions

Comparing version 0.1.8 to 0.2.0

6

exec.js

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

* @module jsexp
* @version 0.1.8
* @version 0.2.0
* @file exec.js

@@ -28,2 +28,4 @@ * usage:

function exec(expression, context) {
var strict = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
if (isValidCondition(expression)) {

@@ -37,3 +39,3 @@ var value = [];

} else {
value.push(getVariableValue(expression[i], context));
value.push(getVariableValue(expression[i], context, strict));
}

@@ -40,0 +42,0 @@

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

* @module jsexp
* @version 0.1.8
* @version 0.2.0
* @file jsep.js

@@ -9,0 +9,0 @@ * usage:

{
"name": "jsexp",
"version": "0.1.8",
"version": "0.2.0",
"license": "MIT",

@@ -5,0 +5,0 @@ "scripts": {

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

* @module jsexp
* @version 0.1.8
* @version 0.2.0
* @file parse.js

@@ -9,0 +9,0 @@ * usage:

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

* @module jsexp
* @version 0.1.8
* @version 0.2.0
* @file rules.js

@@ -9,0 +9,0 @@ * usage:

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

* @module jsexp
* @version 0.1.8
* @version 0.2.0
* @file rulesMap.js

@@ -9,0 +9,0 @@ * usage:

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

* @module jsexp
* @version 0.1.8
* @version 0.2.0
* @file stringify.js

@@ -27,2 +27,3 @@ * usage:

* @param context
* @param strict
* @returns {string}

@@ -33,2 +34,4 @@ */

function stringify(expression, context) {
var strict = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
if (isValidCondition(expression)) {

@@ -48,3 +51,3 @@ var value = [];

} else {
var replacedValue = getVariableValue(expression[i], context);
var replacedValue = getVariableValue(expression[i], context, strict);
value.push(typeof replacedValue === 'string' ? "'".concat(replacedValue, "'") : replacedValue);

@@ -51,0 +54,0 @@ }

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

* @module jsexp
* @version 0.1.8
* @version 0.2.0
* @file transform.js

@@ -9,0 +9,0 @@ * usage:

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

* @module jsexp
* @version 0.1.8
* @version 0.2.0
* @file utils.js

@@ -53,2 +53,3 @@ * usage:

* @param context {object|array}
* @param strict {boolean} 是否只取当前层
* @returns {string|*}

@@ -59,2 +60,4 @@ */

function getVariableValue(variable, context) {
var strict = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
if (context && typeof variable === 'string' && rVariable.test(variable)) {

@@ -74,3 +77,3 @@ var key = variable.substr(1);

if (_value !== undefined) {
if (_value !== undefined || strict) {
return _value;

@@ -77,0 +80,0 @@ }

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

* @module jsexp
* @version 0.1.8
* @version 0.2.0
* @file validate.js

@@ -9,0 +9,0 @@ * usage:

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

* @module jsexp
* @version 0.1.8
* @version 0.2.0
* @file withScope.js

@@ -9,0 +9,0 @@ * usage:

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