Skip to content

Commit 5a9ccf3

Browse files
committed
feat(lint): enforce named exports only via Biome
Add noDefaultExport linting rule to prevent default export patterns that break dual CJS/ESM compatibility. This prevents new modules from using: - export default value - export default X; export { X as 'module.exports' } Named exports work consistently across both module systems, while default exports require .default access, breaking the API consistency.
1 parent 8ba859f commit 5a9ccf3

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

biome.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@
6868
"useLiteralKeys": "off"
6969
},
7070
"style": {
71+
"noDefaultExport": "error",
7172
"noParameterAssign": "off",
7273
"noNonNullAssertion": "off",
7374
"useAsConstAssertion": "error",

0 commit comments

Comments
 (0)