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

eslint-plugin-flowtype-errors

Package Overview
Dependencies
Maintainers
1
Versions
83
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

eslint-plugin-flowtype-errors - npm Package Compare versions

Comparing version 3.0.3 to 3.1.0-0

10

CHANGELOG.md

@@ -0,1 +1,11 @@

## v3.0.3
### Fixed
- Fixed bug that suppressed jsx errors
## v3.0.2
### Updated
- `flow-bin@0.39.0` -> `flow-bin@0.42.0`
## v3.0.1

@@ -2,0 +12,0 @@

6

dist/collect.js

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

exports.default = Collect;
exports.default = collect;

@@ -180,5 +180,5 @@ var _path = require('path');

function Collect(stdin, root, filepath) {
return executeFlow(stdin, root, filepath, {});
function collect(stdin, root, filepath) {
return executeFlow(stdin, root, filepath);
}
module.exports = exports['default'];

@@ -23,2 +23,9 @@ 'use strict';

function hasFlowPragma(source) {
return source.getAllComments().some(function (comment) {
return (/@flow/.test(comment.value)
);
});
}
exports.default = {

@@ -33,3 +40,3 @@ rules: {

if (onTheFly) {
var stdin = context.getSourceCode().getText();
var source = context.getSourceCode();
var root = process.cwd();

@@ -46,12 +53,7 @@

if (stdin) {
if (runOnAllFiles === false) {
// `String.prototype.includes` is an O(n) operation :(
if (!stdin.includes('@flow')) {
return true;
}
}
if (runOnAllFiles === false && !hasFlowPragma(source)) {
return true;
}
collected = (0, _collect2.default)(stdin, root, context.getFilename());
collected = (0, _collect2.default)(source.getText(), root, context.getFilename());
} else {

@@ -58,0 +60,0 @@ collected = (0, _collect2.default)();

{
"name": "eslint-plugin-flowtype-errors",
"version": "3.0.3",
"version": "3.1.0-0",
"description": "Retrieve Flow errors as ESLint errors.",

@@ -13,3 +13,3 @@ "author": "Amila Welihinda",

"build": "cross-env NODE_ENV=production babel src --out-dir dist",
"lint": "eslint --ignore-path .gitignore --cache --format=node_modules/eslint-formatter-pretty .",
"lint": "eslint --cache --format=node_modules/eslint-formatter-pretty .",
"preversion": "npm run build",

@@ -51,2 +51,3 @@ "spec": "npm run build && jest test/format.spec.js",

"cross-env": "^3.2.4",
"cross-spawn": "^5.1.0",
"eslint": "^3.18.0",

@@ -53,0 +54,0 @@ "eslint-config-airbnb-base": "^11.1.1",

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