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

@eslint/create-config

Package Overview
Dependencies
Maintainers
2
Versions
27
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@eslint/create-config - npm Package Compare versions

Comparing version 1.0.0 to 1.0.1

16

lib/config-generator.js

@@ -16,3 +16,3 @@ /**

const jsStyleGuides = [
{ message: "Airbnb: https://github.com/airbnb/javascript", name: "airbnb", value: { packageName: "eslint-config-airbnb", type: "eslintrc" } },
{ message: "Airbnb: https://github.com/airbnb/javascript", name: "airbnb", value: { packageName: "eslint-config-airbnb-base", type: "eslintrc" } },
{ message: "Standard: https://github.com/standard/standard", name: "standard", value: { packageName: "eslint-config-standard", type: "eslintrc" } },

@@ -116,2 +116,3 @@ { message: "XO: https://github.com/xojs/eslint-config-xo", name: "xo", value: { packageName: "eslint-config-xo", type: "eslintrc" } }

if (answers.purpose === "style") {
const choices = this.answers.language === "javascript" ? jsStyleGuides : tsStyleGuides;

@@ -138,3 +139,12 @@ const styleguideAnswer = await enquirer.prompt({

this.result.configFilename = isESMModule ? "eslint.config.js" : "eslint.config.mjs";
this.answers.styleguide = typeof this.answers.styleguide === "string"
? { packageName: this.answers.styleguide, type: "flat" }
: this.answers.styleguide;
// replaced `eslint-config-airbnb-base` with `eslint-config-airbnb`(for react supports)
if (this.answers.styleguide?.packageName === "eslint-config-airbnb-base" && this.answers.framework === "react") {
this.answers.styleguide.packageName = "eslint-config-airbnb";
this.answers.framework = "none";
}
let importContent = "";

@@ -178,5 +188,3 @@ const helperContent = `import path from "path";

} else if (this.answers.purpose === "style") {
const styleguide = typeof this.answers.styleguide === "string"
? { packageName: this.answers.styleguide, type: "flat" }
: this.answers.styleguide;
const styleguide = this.answers.styleguide;

@@ -183,0 +191,0 @@ this.result.devDependencies.push(styleguide.packageName);

{
"name": "@eslint/create-config",
"version": "1.0.0",
"version": "1.0.1",
"description": "Utility to create ESLint config files.",

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

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