You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 7-8.RSVP
Socket
Socket
Sign inDemoInstall

@vue/eslint-config-standard

Package Overview
Dependencies
Maintainers
5
Versions
58
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 7.0.0 to 8.0.0

.eslintrc.cjs

38

package.json
{
"name": "@vue/eslint-config-standard",
"version": "7.0.0",
"description": "eslint-config-standard for Vue CLI",
"main": "index.js",
"version": "8.0.0",
"description": "eslint-config-standard for Vue.js projects",
"main": "index.cjs",
"exports": {
".": "./index.cjs",
"./createAliasSetting": "./createAliasSetting.cjs",
"./package.json": "./package.json"
},
"publishConfig": {

@@ -11,7 +16,9 @@ "access": "public"

"type": "git",
"url": "git+https://github.com/vuejs/eslint-config-standard.git"
"url": "git+https://github.com/vuejs/eslint-config-standard.git",
"directory": "packages/eslint-config-standard"
},
"keywords": [
"vue",
"cli"
"eslint",
"standard"
],

@@ -23,21 +30,18 @@ "author": "Evan You",

},
"homepage": "https://github.com/vuejs/eslint-config-standard#readme",
"homepage": "https://github.com/vuejs/eslint-config-standard/blob/main/packages/eslint-config-standard#readme",
"dependencies": {
"eslint-config-standard": "^17.0.0",
"eslint-import-resolver-custom-alias": "^1.3.0",
"eslint-import-resolver-node": "^0.3.6",
"eslint-import-resolver-webpack": "^0.13.2"
"eslint-plugin-import": "^2.26.0",
"eslint-plugin-n": "^15.2.4",
"eslint-plugin-promise": "^6.0.0"
},
"peerDependencies": {
"@vue/cli-service": "^3.0.0 || ^4.0.0 || ^5.0.0",
"eslint": "^8.0.1",
"eslint-plugin-import": "^2.25.2",
"eslint-plugin-n": "^15.0.0",
"eslint-plugin-promise": "^6.0.0",
"eslint-plugin-vue": "^8.7.1"
"eslint-plugin-vue": "^9.2.0"
},
"peerDependenciesMeta": {
"@vue/cli-service": {
"optional": true
}
"devDependencies": {
"eslint": "^8.20.0"
}
}
}

@@ -1,6 +0,6 @@

# @vue/eslint-config-standard
# `@vue/eslint-config-standard`
> eslint-config-standard for Vue CLI
> eslint-config-standard for Vue
This config is specifically designed to be used by Vue CLI setups
This config is specifically designed to be used by `@vue/cli` & `create-vue` setups
and is not meant for outside use (it can be used but some adaptations

@@ -10,3 +10,61 @@ on the user side might be needed - for details see the config file).

A part of its design is that this config may implicitly depend on
other parts of Vue CLI setups, such as `eslint-plugin-vue` being
other parts of `@vue/cli`/`create-vue` setups, such as `eslint-plugin-vue` being
extended in the same resulting config.
## Installation
In order to work around [a known limitation in ESLint](https://github.com/eslint/eslint/issues/3458), we recommend you to use this package alongside `@rushstack/eslint-patch`, so that you don't have to install too many dependencies:
```sh
npm add --dev @vue/eslint-config-standard @rushstack/eslint-patch
```
## Usage
An example `.eslintrc.cjs`:
```js
require("@rushstack/eslint-patch/modern-module-resolution")
module.exports = {
root: true,
extends: [
'plugin:vue/vue3-essential',
'@vue/eslint-config-standard'
]
}
```
## Aliases
By default, none of the built-in rules require you to configure aliases in ESLint.
But if you want to enable some additional rules that need to actually resolve the imported module on the filesystem (e.g. [`import/no-unresolved`](https://github.com/import-js/eslint-plugin-import/blob/v2.26.0/docs/rules/no-unresolved.md)) by yourself, you should configure it.
In that case, we provided a helper function to simplify the task.
For example, it is a widely accepted convention to use `@` as an alias to the `src` folder in the Vue ecosystem. To enable this, you can use the following config:
```js
require('@rushstack/eslint-patch/modern-module-resolution')
const path = require('node:path')
const createAliasSetting = require('@vue/eslint-config-standard/createAliasSetting')
module.exports = {
root: true,
extends: [
'plugin:vue/vue3-essential',
'@vue/eslint-config-standard'
],
rules: {
'import/no-unresolved': 'error'
}
settings: {
...createAliasSetting({
'@': `${path.resolve(__dirname, './src')}`
})
}
}
```
`createAliasSetting` accepts a map of aliases and their corresponding paths, and returns a settings object to be spread in to the `settings` field of the ESLint config.
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc