我的eslint定义是:
padded-blocks: ["error", { "blocks": "never" }]
我的代码是:
Vue.directive('confirm', {
bind(el, binding) {
el.addEventListener('click', () => {
...
但我还是得到了:
✘ http://eslint.org/docs/rules/padded-blocks Block must not be padded by blank lines
src/directives/confirm.js:6:40
el.addEventListener('click', () => {
这是一些错误吗?
由于
答案 0 :(得分:1)
如果我理解你的例子那么它应该是
padded-blocks: ["error", { "blocks": "always" }]