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

@arnaud-barre/eslint-plugin-custom

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@arnaud-barre/eslint-plugin-custom - npm Package Compare versions

Comparing version 1.0.1 to 1.0.2

2

package.json
{
"name": "@arnaud-barre/eslint-plugin-custom",
"description": "Custom rules for @arnaud-barre/eslint-config",
"version": "1.0.1",
"version": "1.0.2",
"license": "MIT",

@@ -6,0 +6,0 @@ "author": "Arnaud Barré (https://github.com/ArnaudBarre)",

@@ -17,2 +17,8 @@ "use strict";

return;
const value = node.quasis[0].value.raw;
if (value.includes("'") && value.includes('"'))
return;
if (node.loc.start.line !== node.loc.end.line)
return;
const replacer = value.includes('"') ? "'" : '"';
context.report({

@@ -22,4 +28,4 @@ messageId: "error",

fix: (fixer) => [
fixer.replaceTextRange([node.range[0], node.range[0] + 1], '"'),
fixer.replaceTextRange([node.range[1] - 1, node.range[1]], '"'),
fixer.replaceTextRange([node.range[0], node.range[0] + 1], replacer),
fixer.replaceTextRange([node.range[1] - 1, node.range[1]], replacer),
],

@@ -26,0 +32,0 @@ });

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