eslint-plugin-vue-pug से माइग्रेट करना
eslint-plugin-vue-pug खुद को उसी vue-pug key के तहत register करता है, इसलिए दोनों plugins को एक साथ उपयोग नहीं किया जा सकता।
eslint-plugin-vue-pugऔरvue-eslint-parser-template-tokenizer-pugको uninstall करें, और अपने config सेplugin:vue-pug/...entries हटाएँ। इस plugin को flat config चाहिए।- इस plugin को शुरुआत करें की तरह install और configure करें।
- पुराने rules बदलें:
vue-pug/no-parsing-error→vue/no-parsing-error, जो Pug syntax errors रिपोर्ट करता है औरflat/baseको छोड़कर हर eslint-plugin-vue config में चालू है।vue-pug/component-name-in-template-casing→ कोई नहीं:vue/component-name-in-template-casingPug templates पर crash करता है और बंद है।vue-pug/no-pug-control-flowकी id वही रहती है, लेकिन उसके options अलग हैं: पुराना rule कोई options नहीं लेता था और पुरानेstrongly-recommendedconfigs में चालू था; यह{ allow: [...] }लेता है और किसी config में नहीं है। देखें उसके docs।
पुराने configs कुछ layout rules (vue/html-indent, vue/html-self-closing, …) को हर जगह बंद कर देते थे। यहाँ वे HTML templates के लिए चालू रहते हैं और केवल Pug templates के अंदर suppress किए जाते हैं (crash करने वाले को छोड़कर), और उनकी जगह vue-pug/* rules काम करते हैं।