Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changes to filters are not hot reloaded #3504

Open
sebthom opened this issue Oct 24, 2024 · 0 comments
Open

Changes to filters are not hot reloaded #3504

sebthom opened this issue Oct 24, 2024 · 0 comments

Comments

@sebthom
Copy link

sebthom commented Oct 24, 2024

Operating system

Windows 10

Eleventy

3.0.0

Describe the bug

Running 11ty in dev mode and changing filters in 11ty config has no effect on hot reload but require restart of the dev server.

Reproduction steps

  1. Add a custom filter to eleventy.config.cjs, like so:

      const inspect = require("util").inspect
      eleventyConfig.addFilter("inspect", (content) => inspect(content, { sorted:false}))
  2. Use the filter in a page, e.g. index.md, e.g. like

    <pre>{{ collections.all | inspect }}</pre>
  3. launched 11ty in dev mode using npx @11ty/eleventy --serve --quiet --incremental

  4. open the browser and load the index page

  5. modify the filter in eleventy.config.cjs and e.g. change the sorted option from false to true.

  6. the page in the browser will be reloaded but the inspect filter still behaves like before the change. only after restarting the dev server the filters behaviour is updated.

Expected behavior

No response

Reproduction URL

No response

Screenshots

No response

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

No branches or pull requests

2 participants
@sebthom and others