web-infra-dev / web-infra-dev/rslint

[Feature]: All-in-one Rstack ruleset

Open
#2,048 3 comments 1 reaction 0 assignees View on GitHub
Dominant language
Go
Stars
459
Forks
33
Avg merge
1d 2h
Merged PRs (30d)
376

Description

### What problem does this feature solve?

Although it might still be a bit early, we may want to introduce some rules related to `rspack`, `rsbuild`, `rslib`, `rspress`, etc., to provide suggestions and enforce best practices for code using these projects in the future.

For example, we could suggest using the `rspackIgnore` comment instead of `webpackIgnore`, or introduce some rules around `new URL()` usage.

Each project may eventually have its own group of rules, which could otherwise lead to separate Rspack, Rsbuild, Rslib, and Rspress plugins. Instead of creating a standalone plugin for each project, I suggest grouping these rules under a unified `rstack/` ruleset.

### What does the proposed API of configuration look like?

```js
import { rstackPlugin } from '@rslint/core'

export default defineConfig([
rstackPlugin.configs.recommended, // for all projects
rstackPlugin.configs.recommendedRstest, // for users only want rstest rules
rstackPlugin.configs.recommendedRslib, // for users only want rslib rules, will also include upstream project rules (rsbuild and rspack)
rstackPlugin.configs.recommendedRspress, // for users only want rspress and upstream rules
]);
```

Contributor guide

Open the contributing guide

Research direction

The issue names no files, tests, or implementation entry points. Start by reviewing the existing plugin configuration patterns and the proposed rstackPlugin configs, then define the unified ruleset and its project-specific groupings; done means the documented API supports the listed recommended, recommendedRstest, recommendedRslib, and recommendedRspress configurations.

Written by the indexing model from the issue text.

Assessment

Tech stack
go, javascript, typescript
Domain
tooling
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Active
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.