Skip to content

Markdown files are not rebuilt when their "includes" change #4289

Closed
@everdimension

Description

Describe the bug

I have the following vitepress structure:

docs-vitepress
├── endpoints.md
├── entities.md
├── generated
│   ├── endpoints.md
│   └── entities.md
├── index.md
└── overview.md

enpoints.md simply contains an include of ./generated/endpoints.md:

<!--@include: ./generated/endpoints.md-->

This is done to avoid the /generated/ path segment in the URL.

Problem: When content of /generated/endpoints.md changes, content of /endpoints.md doesn't change

Reproduction

https://github.com/everdimension/vitepress-watch-included-issue

Expected behavior

It's expected that when content of /generated/endpoints.md changes, the updates will be reflected in the build

System Info

OS: macOS 13.5.1
Memory: 16 GiB
Architecture: aarch64


  System:
    OS: macOS 13.5.1
    CPU: (8) x64 Apple M1
    Memory: 25.73 MB / 16.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 20.10.0
    Yarn: 1.22.19
    npm: 10.2.5
  Browsers:
    Chrome Canary: 131.0.6778.0
    Safari: 16.6
  npmPackages:
    vitepress: ^1.4.1 => 1.4.1

Additional context

No response

Validations

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingbuildRelated to the build system

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions