New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

eslint-plugin-ember

Package Overview
Dependencies
Maintainers
4
Versions
190
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

eslint-plugin-ember - npm Package Compare versions

Comparing version 3.6.1 to 3.6.2

1

lib/utils/ember.js

@@ -160,2 +160,3 @@ 'use strict';

utils.isArrayExpression(value) ||
utils.isUnaryExpression(value) ||
isCustomObjectProp ||

@@ -162,0 +163,0 @@ utils.isConditionalExpression(value) ||

@@ -7,2 +7,3 @@ 'use strict';

isLiteral,
isUnaryExpression,
isMemberExpression,

@@ -64,2 +65,12 @@ isCallExpression,

/**
* Check whether or not a node is an UnaryExpression.
*
* @param {Object} node The node to check.
* @returns {boolean} Whether or not the node is an Literal.
*/
function isUnaryExpression(node) {
return node !== undefined && node.type === 'UnaryExpression';
}
/**
* Check whether or not a node is an MemberExpression.

@@ -66,0 +77,0 @@ *

8

package.json
{
"name": "eslint-plugin-ember",
"version": "3.6.1",
"version": "3.6.2",
"description": "Eslint plugin for Ember.js apps",

@@ -19,3 +19,3 @@ "main": "index.js",

"type": "git",
"url": "git+https://github.com/netguru/eslint-plugin-ember.git"
"url": "git+https://github.com/ember-cli/eslint-plugin-ember.git"
},

@@ -45,5 +45,5 @@ "keywords": [

"bugs": {
"url": "https://github.com/netguru/eslint-plugin-ember/issues"
"url": "https://github.com/ember-cli/eslint-plugin-ember/issues"
},
"homepage": "https://github.com/netguru/eslint-plugin-ember#readme",
"homepage": "https://github.com/ember-cli/eslint-plugin-ember#readme",
"devDependencies": {

@@ -50,0 +50,0 @@ "babel-eslint": "^7.1.0",

@@ -324,2 +324,11 @@ // ------------------------------------------------------------------------------

},
{
code: `export default Component.extend({
layout,
tabindex: -1,
someComputedValue: computed.reads('count'),
});`,
parserOptions: { ecmaVersion: 6, sourceType: 'module' },
},
],

@@ -606,3 +615,16 @@ invalid: [

},
{
code: `export default Component.extend({
layout,
someComputedValue: computed.reads('count'),
tabindex: -1,
});`,
parserOptions: { ecmaVersion: 6, sourceType: 'module' },
errors: [{
message: 'The "tabindex" property should be above the "someComputedValue" single-line function on line 3',
line: 5,
}],
},
],
});

@@ -300,2 +300,5 @@ 'use strict';

expect(emberUtils.isCustomProp(node)).toBeFalsy();
node = getProperty('test = { test: -1 }');
expect(emberUtils.isCustomProp(node)).toBeTruthy();
});

@@ -302,0 +305,0 @@ });

@@ -48,2 +48,10 @@ 'use strict';

describe('isUnaryExpression', () => {
const node = parse('-1');
it('should check if node is identifier', () => {
expect(utils.isUnaryExpression(node)).toBeTruthy();
});
});
describe('isMemberExpression', () => {

@@ -50,0 +58,0 @@ const node = parse('test.value');

Sorry, the diff of this file is not supported yet

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