1.0.0 • Published 4 years ago
eslint-plugin-markup-replace v1.0.0
eslint-plugin-markup-replace
复制了 eslint-plugin-php-markup
插件
开放php-custom-markup-regex配置, 用于配置正则表达式来替换后端模板标签
需要跟 eslint-plugin-html
插件一起使用
安装
npm install --save-dev eslint-plugin-markup-replace
使用
添加 markup-replace
到 .eslintrc
文件的 plugins
配置中
{
// ...
"plugins": [
"html",
"markup-replace"
],
"settings": {
'html/html-extensions': ['.html', '.tpl'],
'php/php-extensions': ['.tpl'],
'php/php-custom-markup-regex': '(<\\?[\\s\\S]*?\\?>|{[$#].*?})'
},
// ...
}
License
MIT