Skip to content

[docs] Use jsdoc types in config examples #580

Open
@LarsDenBakker

Description

@LarsDenBakker

When documenting config examples, we should use jsdocs to add types for the config. This helps a lot with discoverability of config options.

Example:

//@ts-check
import { playwrightLauncher } from '@web/test-runner-playwright';

export default /** @type {import('@web/test-runner').TestRunnerConfig} */ ({
  files: 'demo/test/pass-*.test.js',
  groups: [
    {
      name: 'group-a',
      browsers: [playwrightLauncher({ product: 'firefox' })],
    },
  ],
});

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentationgood first issueGood for newcomers

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions