File tree 7 files changed +7
-2
lines changed
Filter options
7 files changed +7
-2
lines changed
Original file line number Diff line number Diff line change @@ -182,6 +182,7 @@ Rules in this category are enabled for all presets provided by eslint-plugin-vue
182
182
| [ vue/block-order] | enforce order of component top-level elements | :wrench : | :three ::two ::hammer : |
183
183
| [ vue/no-lone-template] | disallow unnecessary ` <template> ` | | :three ::two ::warning : |
184
184
| [ vue/no-multiple-slot-args] | disallow passing multiple arguments to scoped slots | | :three ::two ::warning : |
185
+ | [ vue/no-required-prop-with-default] | enforce props with default values to be optional | :wrench ::bulb : | :three ::two ::warning : |
185
186
| [ vue/no-v-html] | disallow use of v-html to prevent XSS attack | | :three ::two ::hammer : |
186
187
| [ vue/order-in-components] | enforce order of properties in components | :wrench ::bulb : | :three ::two ::hammer : |
187
188
| [ vue/this-in-template] | disallow usage of ` this ` in template | :wrench : | :three ::two ::hammer : |
@@ -235,7 +236,6 @@ For example:
235
236
| [ vue/no-multiple-objects-in-class] | disallow passing multiple objects in an array to class | | :hammer : |
236
237
| [ vue/no-potential-component-option-typo] | disallow a potential typo in your component property | :bulb : | :hammer : |
237
238
| [ vue/no-ref-object-reactivity-loss] | disallow usages of ref objects that can lead to loss of reactivity | | :warning : |
238
- | [ vue/no-required-prop-with-default] | enforce props with default values to be optional | :wrench ::bulb : | :warning : |
239
239
| [ vue/no-restricted-block] | disallow specific block | | :hammer : |
240
240
| [ vue/no-restricted-call-after-await] | disallow asynchronously called restricted methods | | :hammer : |
241
241
| [ vue/no-restricted-class] | disallow specific classes in Vue components | | :warning : |
Original file line number Diff line number Diff line change @@ -10,6 +10,7 @@ since: v9.6.0
10
10
11
11
> enforce props with default values to be optional
12
12
13
+ - :gear : This rule is included in all of ` "plugin:vue/recommended" ` , ` *.configs["flat/vue2-recommended"] ` , ` "plugin:vue/vue3-recommended" ` and ` *.configs["flat/recommended"] ` .
13
14
- :wrench : The ` --fix ` option on the [ command line] ( https://eslint.org/docs/user-guide/command-line-interface#fix-problems ) can automatically fix some of the problems reported by this rule.
14
15
- :bulb : Some problems reported by this rule are manually fixable by editor [ suggestions] ( https://eslint.org/docs/developer-guide/working-with-rules#providing-suggestions ) .
15
16
Original file line number Diff line number Diff line change @@ -15,6 +15,7 @@ module.exports = [
15
15
'vue/block-order' : 'warn' ,
16
16
'vue/no-lone-template' : 'warn' ,
17
17
'vue/no-multiple-slot-args' : 'warn' ,
18
+ 'vue/no-required-prop-with-default' : 'warn' ,
18
19
'vue/no-v-html' : 'warn' ,
19
20
'vue/order-in-components' : 'warn' ,
20
21
'vue/this-in-template' : 'warn'
Original file line number Diff line number Diff line change @@ -15,6 +15,7 @@ module.exports = [
15
15
'vue/block-order' : 'warn' ,
16
16
'vue/no-lone-template' : 'warn' ,
17
17
'vue/no-multiple-slot-args' : 'warn' ,
18
+ 'vue/no-required-prop-with-default' : 'warn' ,
18
19
'vue/no-v-html' : 'warn' ,
19
20
'vue/order-in-components' : 'warn' ,
20
21
'vue/this-in-template' : 'warn'
Original file line number Diff line number Diff line change @@ -10,6 +10,7 @@ module.exports = {
10
10
'vue/block-order' : 'warn' ,
11
11
'vue/no-lone-template' : 'warn' ,
12
12
'vue/no-multiple-slot-args' : 'warn' ,
13
+ 'vue/no-required-prop-with-default' : 'warn' ,
13
14
'vue/no-v-html' : 'warn' ,
14
15
'vue/order-in-components' : 'warn' ,
15
16
'vue/this-in-template' : 'warn'
Original file line number Diff line number Diff line change @@ -10,6 +10,7 @@ module.exports = {
10
10
'vue/block-order' : 'warn' ,
11
11
'vue/no-lone-template' : 'warn' ,
12
12
'vue/no-multiple-slot-args' : 'warn' ,
13
+ 'vue/no-required-prop-with-default' : 'warn' ,
13
14
'vue/no-v-html' : 'warn' ,
14
15
'vue/order-in-components' : 'warn' ,
15
16
'vue/this-in-template' : 'warn'
Original file line number Diff line number Diff line change @@ -17,7 +17,7 @@ module.exports = {
17
17
type : 'problem' ,
18
18
docs : {
19
19
description : 'enforce props with default values to be optional' ,
20
- categories : undefined ,
20
+ categories : [ 'vue2-recommended' , 'vue3-recommended' ] ,
21
21
url : 'https://eslint.vuejs.org/rules/no-required-prop-with-default.html'
22
22
} ,
23
23
fixable : 'code' ,
You can’t perform that action at this time.
0 commit comments