You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/content/rules/sort-jsx-props.mdx
+68-1
Original file line number
Diff line number
Diff line change
@@ -144,6 +144,7 @@ Specifies the sorting method.
144
144
-`'natural'` — Sort items in a [natural](https://github.com/yobacca/natural-orderby) order (e.g., “item2” < “item10”).
145
145
-`'line-length'` — Sort items by the length of the code line (shorter lines first).
146
146
-`'custom'` — Sort items using the alphabet entered in the [`alphabet`](#alphabet) option.
147
+
-`'unsorted'` — Do not sort items. To be used with the [`useConfigurationIf`](#useconfigurationif) option.
147
148
148
149
### order
149
150
@@ -211,7 +212,7 @@ Specifies the sorting locales. See [String.prototype.localeCompare() - locales](
211
212
-`string` — A BCP 47 language tag (e.g. `'en'`, `'en-US'`, `'zh-CN'`).
212
213
-`string[]` — An array of BCP 47 language tags.
213
214
214
-
### ignorePattern
215
+
### [DEPRECATED]ignorePattern
215
216
216
217
<sub>
217
218
type:
@@ -223,6 +224,8 @@ Specifies the sorting locales. See [String.prototype.localeCompare() - locales](
223
224
</sub>
224
225
<sub>default: `[]`</sub>
225
226
227
+
Use the [useConfigurationIf.tagMatchesPattern](#useconfigurationif) option alongside [type: unsorted](#type) instead.
228
+
226
229
Allows you to specify names or patterns for JSX elements that should be ignored by this rule. This can be useful if you have specific components that you do not want to sort.
227
230
228
231
You can specify their names or a regexp pattern to ignore, for example: `'^Table.+'` to ignore all object types whose names begin with the word Table.
@@ -233,6 +236,68 @@ You can specify their names or a regexp pattern to ignore, for example: `'^Table
233
236
234
237
When `true`, the rule will not sort members if there is an empty line between them. This can be useful for keeping logically separated groups of members in their defined order.
Copy file name to clipboardExpand all lines: docs/content/rules/sort-objects.mdx
+4-2
Original file line number
Diff line number
Diff line change
@@ -292,7 +292,7 @@ Determines whether this rule should be applied to styled-components like librari
292
292
-`true` — Apply the rule to styled-components.
293
293
-`false` — Disable the rule for styled-components.
294
294
295
-
### ignorePattern
295
+
### [DEPRECATED]ignorePattern
296
296
297
297
<sub>
298
298
type:
@@ -304,7 +304,9 @@ Determines whether this rule should be applied to styled-components like librari
304
304
</sub>
305
305
<sub>default: `[]`</sub>
306
306
307
-
Allows you to specify names or patterns for object that should be ignored by this rule. This can be useful if you have specific objects that you do not want to sort.
307
+
Use the [useConfigurationIf.declarationMatchesPattern](#useconfigurationif) option alongside [type: unsorted](#type) instead.
308
+
309
+
Allows you to specify names or patterns for objects that should be ignored by this rule. This can be useful if you have specific objects that you do not want to sort.
308
310
309
311
You can specify their names or a regexp pattern to ignore, for example: `'^User.+'` to ignore all object whose names begin with the word “User”.
0 commit comments