@putout/plugin-putout 29.36.1 → 29.37.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -15,6 +15,7 @@ const {
15
15
  __json,
16
16
  __yaml,
17
17
  __toml,
18
+ compareAny,
18
19
  } = operator;
19
20
 
20
21
  const name = '__putout_plugin_check_replace_code';
@@ -174,11 +175,16 @@ function parseKey(propertyPath) {
174
175
  return [null, key];
175
176
  }
176
177
 
178
+ const MATCHERS = [
179
+ 'module.exports.match = __a',
180
+ 'export const match = __a',
181
+ ];
182
+
177
183
  function hasMatch(path) {
178
184
  const {body} = path.scope.getProgramParent().path.node;
179
185
 
180
186
  for (const current of body) {
181
- if (compare(current, 'module.exports.match = __a'))
187
+ if (compareAny(current, MATCHERS))
182
188
  return true;
183
189
  }
184
190
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@putout/plugin-putout",
3
- "version": "29.36.1",
3
+ "version": "29.37.0",
4
4
  "type": "module",
5
5
  "author": "coderaiser <mnemonic.enemy@gmail.com> (https://github.com/coderaiser)",
6
6
  "description": "🐊Putout plugin helps with plugins development",