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

eslint-plugin-lodash

Package Overview
Dependencies
Maintainers
3
Versions
100
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

eslint-plugin-lodash - npm Package Compare versions

Comparing version 2.3.0 to 2.3.1

9

CHANGELOG.md

@@ -11,4 +11,11 @@ # Change Log

[unreleased]: https://github.com/wix/eslint-plugin-lodash/compare/v2.3.0...HEAD
[unreleased]: https://github.com/wix/eslint-plugin-lodash/compare/v2.3.1...HEAD
## [2.3.1] - 2017-01-17
### Fixed
- Allowed asterisk import in `import-scope` in `full` config ([`4c0335e`][4c0335e])
[4c0335e]: https://github.com/wix/eslint-plugin-lodash/commit/4c0335ec3b5d593b032a7876105bd2cacf2737c9
[2.3.1]: https://github.com/wix/eslint-plugin-lodash/compare/v2.3.1...v2.3.0
## [2.3.0] - 2017-01-16

@@ -15,0 +22,0 @@ ### Added

17

lib/rules/import-scope.js

@@ -20,2 +20,3 @@ /**

var every = require('lodash/every');
var includes = require('lodash/includes');

@@ -25,9 +26,9 @@ var messages = {

member: 'Import members from the full Lodash module.',
full: 'Use the full Lodash module'
full: 'Use the full Lodash module.'
};
var importNodeTypes = {
method: 'ImportDefaultSpecifier',
member: 'ImportSpecifier',
full: 'ImportDefaultSpecifier'
method: ['ImportDefaultSpecifier'],
member: ['ImportSpecifier'],
full: ['ImportDefaultSpecifier', 'ImportNamespaceSpecifier']
};

@@ -38,2 +39,7 @@

};
var allImportsAreOfType = function allImportsAreOfType(node, types) {
return every(node.specifiers, function (specifier) {
return includes(types, specifier.type);
});
};

@@ -55,4 +61,3 @@ module.exports = {

} else {
var type = importNodeTypes[importType];
if (!every(node.specifiers, { type: type })) {
if (!allImportsAreOfType(node, importNodeTypes[importType])) {
context.report(node, messages[importType]);

@@ -59,0 +64,0 @@ }

{
"name": "eslint-plugin-lodash",
"version": "2.3.0",
"version": "2.3.1",
"author": "Omer Ganim <ganimomer@gmail.com>",

@@ -5,0 +5,0 @@ "description": "Lodash specific linting rules for ESLint",

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