🚀. Socket Launch Week Day 3:Socket Firewall Now Blocks Malicious VS Code and Open VSX Extensions.Learn more
Sign In

@endo/eslint-plugin

Package Overview
Dependencies
Maintainers
5
Versions
53
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@endo/eslint-plugin - npm Package Compare versions

Comparing version
2.3.0
to
2.3.1
+1
-4
lib/configs/daemon.js

@@ -0,7 +1,4 @@

// @deprecated use @endo/internal
module.exports = {
extends: ['plugin:@endo/internal'],
rules: {
'@endo/no-optional-chaining': 'off',
'@endo/no-nullish-coalescing': 'off',
},
};
+6
-6

@@ -14,4 +14,9 @@ /* eslint-env node */

const parserOptions = {
useProjectService: true,
sourceType: 'module',
projectService: {
allowDefaultProject: ['*.js'],
defaultProject: 'tsconfig.json',
},
tsconfigRootDir: path.join(__dirname, '../../../..'),
EXPERIMENTAL_useProjectService: true,
project: [rootTsProjectGlob],

@@ -48,7 +53,2 @@ };

'import/no-unresolved': ['error', { ignore: ['ava'] }],
// Agoric still uses Endo dependencies under an emulation of ESM we call RESM
// because it is invoked with `node -r esm`.
// RESM does not support ?? nor ?. operators, so we must avoid them expressly.
'@endo/no-optional-chaining': 'error',
'@endo/no-nullish-coalescing': 'error',
'@typescript-eslint/naming-convention': [

@@ -55,0 +55,0 @@ 'error',

{
"name": "@endo/eslint-plugin",
"version": "2.3.0",
"version": "2.3.1",
"description": "ESLint plugin for using Endo",

@@ -17,3 +17,2 @@ "keywords": [

"lint-fix": "exit 0",
"lint-check": "exit 0",
"postpack": "git clean -f '*.d.ts*' '*.tsbuildinfo'"

@@ -24,8 +23,8 @@ },

"tsutils": "~3.21.0",
"typescript": "~5.6.3",
"typescript-eslint": "^7.3.1"
"typescript": "~5.8.3",
"typescript-eslint": "^8.33.0"
},
"devDependencies": {
"@types/mocha": "^10",
"eslint": "^8.57.0",
"eslint": "^8.57.1",
"mocha": "^10.6.0"

@@ -54,3 +53,3 @@ },

],
"gitHead": "e0683e0bfdbfc84351af332c9e78813d7b67ef89"
"gitHead": "571b7803cf10df7cb4fa9d70e4d53a0b53767fa8"
}

@@ -11,5 +11,5 @@ # Security Policy

SES stands for fearless cooperation, and strong security requires strong collaboration with security researchers. If you believe that you have found a security sensitive bug that should not be disclosed until a fix has been made available, we encourage you to report it. To report a bug in HardenedJS, you have several options that include:
SES stands for fearless cooperation, and strong security requires strong collaboration with security researchers. If you believe that you have found a security sensitive bug that should not be disclosed until a fix has been made available, we encourage you to report it. To report a bug in HardenedJS, you have several options that include:
* Reporting the issue to the [Agoric HackerOne vulnerability rewards program](https://hackerone.com/agoric).
* Reporting the issue to the [Agoric HackerOne vulnerability rewards program](https://hackerone.com/agoric).

@@ -16,0 +16,0 @@ * Sending an email to security at (@) agoric.com., encrypted or unencrypted. To encrypt, please use @Warner’s personal GPG key [A476E2E6 11880C98 5B3C3A39 0386E81B 11CAA07A](http://www.lothar.com/warner-gpg.html) .

'use strict';
// Agoric still uses Endo dependencies under an emulation of ESM we call RESM
// because it is invoked with `node -r esm`.
// RESM does not support ?? nor ?. operators, so we must avoid them expressly.
// TODO remove when https://github.com/Agoric/agoric-sdk/issues/8671
module.exports = {
meta: {
docs: {
description: 'disallow nullish coalescing.',
category: 'ES2020',
recommended: false,
url: 'https://github.com/endojs/endo/blob/master/packages/eslint-plugin/lib/rules/no-nullish-coalescing.js',
},
fixable: null,
messages: {
forbidden: 'ES2020 nullish coalescing is forbidden.',
},
schema: [],
type: 'problem',
},
create(context) {
return {
LogicalExpression(node) {
if (node.operator === '??') {
context.report({
node,
messageId: 'forbidden',
});
}
},
};
},
};
/** @author Yosuke Ota <https://github.com/ota-meshi> */
'use strict';
// Agoric still uses Endo dependencies under an emulation of ESM we call RESM
// because it is invoked with `node -r esm`.
// RESM does not support ?? nor ?. operators, so we must avoid them expressly.
// TODO remove when https://github.com/Agoric/agoric-sdk/issues/8671
module.exports = {
meta: {
docs: {
description: 'disallow optional chaining.',
category: 'ES2020',
recommended: false,
url: 'http://mysticatea.github.io/eslint-plugin-es/rules/no-optional-chaining.html',
},
fixable: null,
messages: {
forbidden: 'ES2020 optional chaining is forbidden.',
},
schema: [],
type: 'problem',
},
create(context) {
const sourceCode = context.getSourceCode();
/**
* @param {Token} token The token to check.
* @returns {boolean} whether the token is a `?.` token.
*/
function isQuestionDotToken(token) {
return (
token.value === '?.' &&
(token.type === 'Punctuator' || // espree has been parsed well.
// espree@7.1.0 doesn't parse "?." tokens well. Therefore, get the string from the source code and check it.
sourceCode.getText(token) === '?.')
);
}
return {
'CallExpression[optional=true]'(node) {
context.report({
node: sourceCode.getTokenAfter(node.callee, isQuestionDotToken),
messageId: 'forbidden',
});
},
'MemberExpression[optional=true]'(node) {
context.report({
node: sourceCode.getTokenAfter(node.object, isQuestionDotToken),
messageId: 'forbidden',
});
},
};
},
};