> ## Documentation Index
> Fetch the complete documentation index at: https://learn.mintlify.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Workflow overview

> Follow a documentation change from a fresh branch through review and deployment.

export const Quiz = ({question, answers, correctFeedback, incorrectFeedback}) => {
  const [selected, setSelected] = React.useState(null);
  const [checked, setChecked] = React.useState(false);
  const quizId = React.useId();
  const isCorrect = checked && answers[selected]?.correct;
  const reset = () => {
    setSelected(null);
    setChecked(false);
  };
  return <div className={"quiz-container" + (checked ? " quiz-checked" : "")}>
      <Badge color="green">Quiz</Badge>
      <p className="quiz-question" id={quizId + "-question"}>{question}</p>
      <div className="quiz-options" role="radiogroup" aria-labelledby={quizId + "-question"} aria-disabled={checked}>
        {answers.map((answer, i) => <label key={i} className={["quiz-option", !checked && selected === i ? "quiz-option-selected" : "", checked && answer.correct ? "quiz-option-correct" : "", checked && selected === i && !answer.correct ? "quiz-option-incorrect" : ""].filter(Boolean).join(" ")}>
            <input type="radio" name={"quiz-" + quizId} checked={selected === i} onChange={() => !checked && setSelected(i)} disabled={checked} />
            <span className="quiz-radio" />
            <span className="quiz-option-label">{answer.text}</span>
          </label>)}
      </div>
      {checked && <div className={"quiz-feedback " + (isCorrect ? "quiz-feedback-correct" : "quiz-feedback-incorrect")} role="status" aria-live="polite" aria-atomic="true">
          <span className="quiz-feedback-icon">{isCorrect ? "✓" : "✗"}</span>
          {isCorrect ? correctFeedback : incorrectFeedback}
        </div>}
      <div className="quiz-actions">
        {!checked ? <button className="quiz-btn quiz-btn-check" type="button" onClick={() => selected !== null && setChecked(true)} disabled={selected === null}>
            Check answer
          </button> : <button className="quiz-btn quiz-btn-reset" type="button" onClick={reset}>
            Try again
          </button>}
      </div>
    </div>;
};

<iframe className="w-full aspect-video rounded-xl" src="https://www.youtube.com/embed/WrK6AX8gcrQ" title="Workflow overview" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowFullScreen />

The web editor and a local editor lead to the same place: a branch with a focused change, a pull request for review, and a merge into your deployment branch.

This lesson follows that review-based workflow. Mintlify can also publish directly from an unprotected deployment branch, so match the steps to your team's branch rules.

## Work in the web editor

<Steps>
  <Step title="Create a feature branch">
    Open the branch menu in the editor toolbar and select **Create new branch**. Give the branch a name that describes the change, such as `update-auth-guide`.

    Creating the branch first keeps your edits separate from the deployed version.
  </Step>

  <Step title="Make and review your changes">
    Edit the page in visual or Markdown mode. The editor saves your work automatically.

    Use the live preview as you write. Before publishing, open the changed-file list in the publish menu and review the diff for anything you didn't intend to change.
  </Step>

  <Step title="Save the branch and create a pull request">
    Click **Publish**, save the changes to your feature branch, and select **Create pull request**. Add a short title and explain what changed and why.

    The available publish actions depend on the current branch and its protection rules. If you're on an unprotected deployment branch, Mintlify may also offer to publish directly.
  </Step>

  <Step title="Review and merge">
    Check the preview deployment and ask for any review your team requires. When the pull request is ready, merge it into the deployment branch to publish the change.
  </Step>
</Steps>

## Work locally

<Steps>
  <Step title="Update the deployment branch">
    Switch to the branch your site deploys from, then update it. This example uses `main`:

    ```bash theme={null}
    git switch main
    git pull --ff-only
    ```

    Switching first matters. Running a pull command on another branch can bring changes into the wrong place.
  </Step>

  <Step title="Create a feature branch">
    Create the branch from the updated deployment branch:

    ```bash theme={null}
    git switch -c update-auth-guide
    ```
  </Step>

  <Step title="Preview and edit">
    From the directory containing `docs.json`, start the local preview:

    ```bash theme={null}
    mint dev
    ```

    Edit your MDX files and check the rendered result as you work.
  </Step>

  <Step title="Review the change">
    Inspect both the affected files and their exact edits:

    ```bash theme={null}
    git status
    git diff
    ```

    Look for temporary notes, secrets, generated files, and unrelated edits before staging anything.
  </Step>

  <Step title="Commit the files that belong together">
    Stage the files you reviewed, then commit them:

    ```bash theme={null}
    git add guides/authentication.mdx
    git commit -m "Clarify authentication setup"
    ```

    Add more paths when they belong to the same change. Avoid staging the whole repository by habit.
  </Step>

  <Step title="Push and open a pull request">
    Push the new branch and set its upstream connection:

    ```bash theme={null}
    git push -u origin update-auth-guide
    ```

    Follow GitHub's link or open the repository to create a pull request. Explain the purpose of the change and point reviewers to anything that needs special attention.
  </Step>

  <Step title="Check the preview and merge">
    Open the Mintlify preview from the pull request. After the change passes your team's review and checks, merge it into the deployment branch.
  </Step>
</Steps>

## Respond to review feedback

Keep using the same branch and pull request. Make the requested edit, review it, and push another commit:

```bash theme={null}
git add guides/authentication.mdx
git commit -m "Clarify authentication prerequisites"
git push
```

GitHub adds the commit to the open pull request, and Mintlify updates its preview. You don't need to start the workflow again.

## What Mintlify adds to the pull request

With the GitHub app connected, Mintlify generates a preview deployment for the proposed branch. The preview shows the rendered site, including navigation and components that are difficult to judge from a text diff.

Your team may also enable CI checks for broken links or prose style. These checks are configurable and may depend on your Mintlify plan; they aren't a replacement for reading the changed page.

<Quiz
  question="You're editing on a feature branch in the Mintlify web editor and are ready for team review. What should you do?"
  answers={[
{ text: "Save the branch and create a pull request from the publish menu", correct: true },
{ text: "Copy the edits to the deployment branch manually", correct: false },
{ text: "Wait for autosave to publish the page", correct: false },
{ text: "Create another branch for the review", correct: false },
]}
  correctFeedback="Right. Saving records the edits on the feature branch, and the pull request gives your team a diff and preview to review."
  incorrectFeedback="Use the publish menu to save the feature branch and create a pull request. Autosave preserves editor work, but it doesn't publish the change."
/>

Next up: [Best practices for branches](/courses/git-github/branches) — keep each branch focused enough to review and merge confidently.
