File tree 3 files changed +23
-20
lines changed
3 files changed +23
-20
lines changed Original file line number Diff line number Diff line change 1
1
# Changelog
2
2
3
+ ## 0.4.16
4
+
5
+ Fix CJS/ESM interop issue. Sorry everyone for the trouble.
6
+
3
7
## 0.4.15
4
8
5
9
### Add support for custom HOCs (#60 )
Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " eslint-plugin-react-refresh" ,
3
- "version" : " 0.4.15 " ,
3
+ "version" : " 0.4.16 " ,
4
4
"type" : " module" ,
5
5
"license" : " MIT" ,
6
6
"scripts" : {
Original file line number Diff line number Diff line change 1
1
import { onlyExportComponents } from "./only-export-components.ts" ;
2
2
3
- const plugin = {
4
- rules : {
5
- "only-export-components" : onlyExportComponents ,
6
- } ,
3
+ export const rules = {
4
+ "only-export-components" : onlyExportComponents ,
7
5
} ;
6
+ const plugin = { rules } ;
8
7
9
- export default {
10
- rules : plugin . rules ,
11
- configs : {
12
- recommended : {
13
- plugins : { "react-refresh" : plugin } ,
14
- rules : { "react-refresh/only-export-components" : "error" } ,
15
- } ,
16
- vite : {
17
- plugins : { "react-refresh" : plugin } ,
18
- rules : {
19
- "react-refresh/only-export-components" : [
20
- "error" ,
21
- { allowConstantExport : true } ,
22
- ] ,
23
- } ,
8
+ export const configs = {
9
+ recommended : {
10
+ plugins : { "react-refresh" : plugin } ,
11
+ rules : { "react-refresh/only-export-components" : "error" } ,
12
+ } ,
13
+ vite : {
14
+ plugins : { "react-refresh" : plugin } ,
15
+ rules : {
16
+ "react-refresh/only-export-components" : [
17
+ "error" ,
18
+ { allowConstantExport : true } ,
19
+ ] ,
24
20
} ,
25
21
} ,
26
22
} ;
23
+
24
+ // Probably not needed, but keep for backwards compatibility
25
+ export default { rules, configs } ;
You can’t perform that action at this time.
0 commit comments