版博士V2.0程序
Nelze vybrat více než 25 témat Téma musí začínat písmenem nebo číslem, může obsahovat pomlčky („-“) a může být dlouhé až 35 znaků.
 
 
 
 

34 řádky
886 B

  1. /**
  2. * @author Yosuke Ota
  3. * See LICENSE file in root directory for full license.
  4. */
  5. 'use strict'
  6. const utils = require('../utils')
  7. const slotScopeAttribute = require('./syntaxes/slot-scope-attribute')
  8. module.exports = {
  9. meta: {
  10. type: 'suggestion',
  11. docs: {
  12. description:
  13. 'disallow deprecated `slot-scope` attribute (in Vue.js 2.6.0+)',
  14. categories: ['vue3-essential'],
  15. url: 'https://eslint.vuejs.org/rules/no-deprecated-slot-scope-attribute.html'
  16. },
  17. fixable: 'code',
  18. schema: [],
  19. messages: {
  20. forbiddenSlotScopeAttribute: '`slot-scope` are deprecated.'
  21. }
  22. },
  23. /** @param {RuleContext} context */
  24. create(context) {
  25. const templateBodyVisitor = slotScopeAttribute.createTemplateBodyVisitor(
  26. context,
  27. { fixToUpgrade: true }
  28. )
  29. return utils.defineTemplateBodyVisitor(context, templateBodyVisitor)
  30. }
  31. }