Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Docs: render snapshots of all rule doc example eslint output #8382

Closed
Labels
accepting prsGo ahead, send a pull request that resolves this issuedocumentationDocumentation ("docs") that needs adding/updatinglocked due to agePlease open a new issue if you'd like to say more. See https://typescript-eslint.io/contributing.package: eslint-pluginIssues related to @typescript-eslint/eslint-plugintestsanything to do with testing
@bradzacher

Description

@bradzacher

Before You File a Documentation Request Please Confirm You Have Done The Following...

Suggested Changes

We've had a number of docs issues where the errors reported on an example block were not correct. The big reason this occurs is a few reasons:

  1. we don't validate the examples at all
  2. it's really hard for a reviewer to visualise the errors (open pr, click netlify preview link, navigate to docs, pick example, click open in playground, preview errors - PHEW that's a lot of steps)
  3. we have no way to visualise changes to the errors over time - so changes to rule behaviour that may remove or add errors aren't tracked.

For each rule doc code block we should render a snapshot output for each of its code samples which is the result of running the rule+config on the snapshot.
We could even make this a test which enforces that "valid" examples have no errors.

This would go hand-in-hand with#8381 to allow us to pre-visualise the shiki output and would be a natural partner to#6994.

Affected URL(s)

docs/rules/*

Metadata

Metadata

Assignees

No one assigned

    Labels

    accepting prsGo ahead, send a pull request that resolves this issuedocumentationDocumentation ("docs") that needs adding/updatinglocked due to agePlease open a new issue if you'd like to say more. See https://typescript-eslint.io/contributing.package: eslint-pluginIssues related to @typescript-eslint/eslint-plugintestsanything to do with testing

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp