Skip to content

ci: add markdown, website, and image lint checks#1010

Open
vdusek wants to merge 7 commits into
masterfrom
ci/markdown-website-image-lint
Open

ci: add markdown, website, and image lint checks#1010
vdusek wants to merge 7 commits into
masterfrom
ci/markdown-website-image-lint

Conversation

@vdusek

@vdusek vdusek commented Jun 24, 2026

Copy link
Copy Markdown
Contributor

Adds Markdown, website, and image lint checks to CI, mirroring the setup in apify-docs and apify-core. The docs and website now go through the same kind of automated checks as the Python code.

The website tooling moves from eslint + prettier (which weren't wired into CI) to oxlint and oxfmt, and markdownlint now covers the Markdown files.

Three jobs run in the existing Checks workflow:

  • Markdown lintmarkdownlint over README.md, CONTRIBUTING.md, and the docs/ folder.
  • Website lint and formatoxlint plus an oxfmt --check formatting gate for the Docusaurus site.
  • Image lint — fails when a PR adds unoptimized raster images, which should be converted with pnpm opt:images first.

Notes:

  • The website JS keeps single quotes, set via .editorconfig (quote_type) and .oxfmtrc.json (singleQuote).
  • The markdownlint config matches apify-docs: line length is disabled and inline HTML is allowed.
  • Minor doc and code fixes were applied where needed to pass the new checks.

Closes #754

@vdusek vdusek added adhoc Ad-hoc unplanned task added during the sprint. t-tooling Issues with this label are in the ownership of the tooling team. labels Jun 24, 2026
@vdusek vdusek self-assigned this Jun 24, 2026
@github-actions github-actions Bot added this to the 143rd sprint - Tooling team milestone Jun 24, 2026
@codecov

codecov Bot commented Jun 24, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 91.51%. Comparing base (3c294fa) to head (877f837).

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1010      +/-   ##
==========================================
- Coverage   91.58%   91.51%   -0.07%     
==========================================
  Files          50       50              
  Lines        3160     3160              
==========================================
- Hits         2894     2892       -2     
- Misses        266      268       +2     
Flag Coverage Δ
e2e 35.88% <ø> (ø)
integration 56.67% <ø> (ø)
unit 80.37% <ø> (-0.07%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@vdusek vdusek marked this pull request as ready for review June 24, 2026 08:36
@vdusek vdusek requested a review from szaganek as a code owner June 24, 2026 08:36
@vdusek vdusek requested review from Pijukatel and removed request for szaganek June 24, 2026 08:36
@Pijukatel Pijukatel requested a review from Copilot June 24, 2026 10:21

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR extends the repository’s CI “Checks” workflow with additional linting/quality gates for documentation and the Docusaurus website, and migrates the website toolchain from ESLint/Prettier to oxlint/oxfmt while aligning Markdown linting rules with Apify docs conventions.

Changes:

  • Add CI jobs for Markdown linting, website lint/format checks, and failing PRs that introduce unoptimized raster images.
  • Replace website ESLint/Prettier setup with oxlint/oxfmt configuration and update website sources accordingly.
  • Introduce a shared markdownlint configuration and apply formatting tweaks across docs/markdown files to satisfy the new rules.

Reviewed changes

Copilot reviewed 20 out of 26 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
website/tools/utils/externalLink.js Switch to node:url import and apply formatter-driven style changes.
website/tools/docs-prettier.config.js Remove obsolete Prettier config (toolchain migration).
website/src/theme/DocItem/Content/index.js Add missing semicolon (format consistency).
website/src/plugins/docusaurus-plugin-segment/segment.js Reformat ternary export/object formatting.
website/src/components/RunnableCodeBlock.jsx Reformat JSX (including inline SVG) and simplify render branch.
website/src/components/Highlights.jsx Reformat JSX/whitespace handling in descriptions and icon block.
website/src/components/Gradients.jsx Reformat SVG markup to multi-line/self-closing style.
website/sidebars.js Minor indentation adjustment from formatter.
website/roa-loader/index.js Remove redundant await around fetch call.
website/pnpm-lock.yaml Update lockfile for new lint/format tooling dependencies.
website/package.json Replace lint/format scripts and swap devDependencies to oxlint/oxfmt + markdownlint.
website/oxlint.config.ts Add oxlint configuration (React plugin, ignores, rule overrides).
website/docusaurus.config.js Inline type-cast formatting change (no behavior change intended).
website/.oxfmtrc.json Add oxfmt configuration (width + ignore patterns).
website/.eslintrc.json Remove obsolete ESLint configuration.
README.md Adjust Markdown table separator formatting.
docs/04_upgrading/upgrading_to_v4.md Add spacing/blank lines for Markdown lint compliance.
docs/04_upgrading/upgrading_to_v3.md Add spacing/blank lines for Markdown lint compliance.
docs/04_upgrading/upgrading_to_v2.md Fix list indentation for Markdown lint compliance.
docs/03_guides/09_browser_use.mdx Reformat MDX comment whitespace.
docs/03_guides/06_scrapy.mdx Reformat MDX comment whitespace.
docs/02_concepts/09_logging.mdx Remove local markdownlint directives now redundant with global config.
CONTRIBUTING.md Document new lint/format commands and image optimization workflow.
.markdownlint.yaml Add repository markdownlint ruleset aligned to docs/MDX usage.
.github/workflows/_checks.yaml Add Markdown/website/image lint jobs and Node version env.
.editorconfig Add quote_type = single to align formatting expectations.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread website/package.json Outdated

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 20 out of 26 changed files in this pull request and generated 2 comments.

Comment thread CONTRIBUTING.md
Comment thread .github/workflows/_checks.yaml

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 20 out of 26 changed files in this pull request and generated no new comments.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

adhoc Ad-hoc unplanned task added during the sprint. t-tooling Issues with this label are in the ownership of the tooling team.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add markdownlint validation and eslint for website

3 participants