oxc/crates/oxc_linter
Alexander S. 41f2070895
fix(linter): rule no-restricted-imports support missing options (#8076)
> The regex property is used to specify the regex patterns for
restricting modules.
> Note: regex cannot be used in combination with group.

_https://eslint.org/docs/latest/rules/no-restricted-imports#regex_

> This option allows you to use regex patterns to restrict import names:


_https://eslint.org/docs/latest/rules/no-restricted-imports#importnamepattern_

> This is a string option. Inverse of importNamePattern, this option
allows imports that matches the specified regex pattern. So it restricts
all imports from a module, except specified allowed patterns.
> Note: allowImportNamePattern cannot be used in combination with
importNames, importNamePattern or allowImportNames.


_https://eslint.org/docs/latest/rules/no-restricted-imports#allowimportnamepattern_

Needed to install `regress` to support JS Sntax like Lookaheads and
Lookbehinds

Next Goals:
- https://github.com/oxc-project/oxc/pull/7894
- Improve spans
- Error for wrong configurations
- update documentation
- Output messages like
[eslint](https://github.com/eslint/eslint/blob/main/lib/rules/no-restricted-imports.js#L140-L184)
2025-01-18 11:50:36 +08:00
..
examples refactor(oxc): remove useless allocator.alloc(program) calls (#6571) 2024-10-15 02:21:20 +00:00
fixtures test(linter): add regression tests for import/namespace (#7723) 2024-12-08 15:35:14 +08:00
src fix(linter): rule no-restricted-imports support missing options (#8076) 2025-01-18 11:50:36 +08:00
tests test(linter): use plugin name instead of category for finding rule (#8353) 2025-01-09 10:48:11 +08:00
Cargo.toml release(oxlint): v0.15.6 (#8456) 2025-01-13 11:08:34 +08:00
CHANGELOG.md release(oxlint): v0.15.6 (#8456) 2025-01-13 11:08:34 +08:00