Skip to content

[Feature request] Config option to disable prefetch links, or only prefetch certain pages #636

Closed
@jakeg

Description

@jakeg

Feature request

What problem does this feature solve?

Sites with many pages don't want to prefetch all pages. For example, a site with 1,000+ pages may want to prefetch no pages, or a small selection of main pages.

What does the proposed API look like?

In .vuepress/config.js add an option prefetch which defaults to true but can be changed to false to not prefetch any pages, or an array of pages.

module.exports = {
  // To not do any prefetching of pages
  prefetch: false,
  // Or to prefetch a selection of main pages
  prefetch: [
    '/about',
    '/faq',
    '/contact'  
  ]
}

How should this be implemented in your opinion?

Are you willing to work on this yourself?**

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions