Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions fern/products/docs/pages/changelog/2026-03-09.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
tags: ["local-development", "configuration"]
---

## Preview workflow with direct page links

You can now use an updated GitHub Actions preview workflow that comments on your pull request with direct links to every page you changed, so reviewers can jump straight to affected pages without navigating through the full site. The comment updates with a new preview link and refreshed page links when you push new commits.

<Frame>
<img
src="../getting-started/images/markdown-links-preview.png"
alt="GitHub Actions bot comment showing a preview URL and a list of direct links to changed documentation pages"
/>
</Frame>

To adopt this workflow, replace your `.github/workflows/preview-docs.yml` with the updated version. New sites created through the [guided UI](https://dashboard.buildwithfern.com/get-started) or [CLI quickstart](/learn/docs/getting-started/quickstart) include it automatically.

<Button intent="none" outlined rightIcon="arrow-right" href="/learn/docs/preview-publish/preview-changes#automate-with-github-actions">Read the docs</Button>
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,16 @@ fern docs preview delete <url>

### Automate with GitHub Actions

If you set up your site using the [guided UI](https://dashboard.buildwithfern.com/get-started) or [CLI quickstart](/learn/docs/getting-started/quickstart), preview workflow files are automatically included in your repository. Otherwise, add them manually using the examples below.
You can use a GitHub Actions workflow to automatically generate a preview URL when a pull request is opened. The workflow posts a comment on the PR with the preview link and direct links to every page changed in the PR, so reviewers can jump straight to affected pages. When you push new commits, the comment is updated with a new preview link and refreshed page links.

<Frame>
<img
src="./images/markdown-links-preview.png"
alt="GitHub Actions bot comment on a pull request showing a preview URL and direct links to changed documentation pages"
/>
</Frame>

If you set up your site using the [guided UI](https://dashboard.buildwithfern.com/get-started) or [CLI quickstart](/learn/docs/getting-started/quickstart), this workflow is automatically included in your repository. Otherwise, add it manually using the examples below.

These workflows require a `FERN_TOKEN` [repository secret](https://docs.github.com/en/actions/security-guides/using-secrets-in-github-actions#creating-secrets-for-a-repository). If you used the guided workflow, this secret is added automatically. Otherwise, run [`fern token`](/learn/cli-api-reference/cli-reference/commands#fern-token) in your terminal to generate a token, then add it in your repository's **Settings > Secrets and variables > Actions** with the name `FERN_TOKEN`.

Expand Down
Loading