Commit 899b8b4
committed
feat(linter): allow namespace re-export in
Re-exporting as a namespace has no workarounds so should be allowed:
In test.js:
```js
export function Foo() {}
export * as Example from './test.js';
```
But, re-exporting it-self should be disallowed:
```js
export function Foo() {}
export * from './test.js';
```
fixes #11646
closes #11671import/no-cycle (#11995)1 parent bcd5813 commit 899b8b4
File tree
3 files changed
+33
-0
lines changed- crates/oxc_linter/src
- rules/import
- snapshots
3 files changed
+33
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
385 | 385 | | |
386 | 386 | | |
387 | 387 | | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
| 391 | + | |
| 392 | + | |
388 | 393 | | |
389 | 394 | | |
390 | 395 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
162 | 162 | | |
163 | 163 | | |
164 | 164 | | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
165 | 183 | | |
166 | 184 | | |
167 | 185 | | |
| |||
271 | 289 | | |
272 | 290 | | |
273 | 291 | | |
| 292 | + | |
274 | 293 | | |
275 | 294 | | |
276 | 295 | | |
| |||
379 | 398 | | |
380 | 399 | | |
381 | 400 | | |
| 401 | + | |
382 | 402 | | |
383 | 403 | | |
384 | 404 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
279 | 279 | | |
280 | 280 | | |
281 | 281 | | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
0 commit comments