# Introduction
eslint-plugin-yml (opens new window) is ESLint plugin provides linting rules for YAML (opens new window).
(opens new window)
(opens new window)
(opens new window)
(opens new window)
(opens new window)
(opens new window)
(opens new window)
(opens new window)
(opens new window)
# 📛 Features
This ESLint plugin provides linting rules for YAML (opens new window).
- You can use ESLint to lint YAML (opens new window).
- You can find out the problem with your YAML (opens new window) files.
- You can apply consistent code styles to your YAML (opens new window) files.
- Supports Vue SFC (opens new window) custom blocks such as
<i18n lang="yaml">
.
Requirementsvue-eslint-parser
v7.3.0 and above. - Supports ESLint directives. e.g.
# eslint-disable-next-line
- You can check your code in real-time using the ESLint editor integrations.
You can check on the Online DEMO.
# ❓ How is it different from other YAML plugins?
# Plugins that do not use AST
e.g. eslint-plugin-yaml (opens new window)
These plugins use the processor to parse and return the results independently, without providing the ESLint engine with AST and source code text.
Plugins don't provide AST, so you can't use directive comments (e.g. # eslint-disable
).
Plugins don't provide source code text, so you can't use it with plugins and rules that use text (e.g. eslint-plugin-prettier (opens new window), eol-last (opens new window)).
eslint-plugin-yml works by providing AST and source code text to ESLint.
# 📖 Usage
See User Guide.
# ✅ Rules
See Available Rules.
# 🚀 To Do More Verification
# Verify using JSON Schema
You can verify using JSON Schema by checking and installing eslint-plugin-json-schema-validator (opens new window).
# Verify the Vue I18n (opens new window) message resource files
You can verify the message files by checking and installing @intlify/eslint-plugin-vue-i18n (opens new window).
# 👫 Related Packages
- eslint-plugin-jsonc (opens new window) ... ESLint plugin for JSON, JSON with comments (JSONC) and JSON5.
- eslint-plugin-toml (opens new window) ... ESLint plugin for TOML.
- eslint-plugin-json-schema-validator (opens new window) ... ESLint plugin that validates data using JSON Schema Validator.
- jsonc-eslint-parser (opens new window) ... JSON, JSONC and JSON5 parser for use with ESLint plugins.
- yaml-eslint-parser (opens new window) ... YAML parser for use with ESLint plugins.
- toml-eslint-parser (opens new window) ... TOML parser for use with ESLint plugins.
# 🔒 License
See the LICENSE file for license rights and limitations (MIT).