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

BUGFIX: Fix crashing bug when embeded file changed while in --watch mode #56

Merged
merged 2 commits into from
May 11, 2024

Conversation

carbontwelve
Copy link
Contributor

This PR fixes a bug raised in #33 by swapping out usage of EleventyRenderPlugin.RenderManager for EleventyRenderPlugin.String which is the exported template render function.

EleventyRenderPlugin.RenderManager ignores the templateConfig value passed to it, instead choosing to use its own internal state. When 11ty runs in --watch mode that internal state becomes different to what 11ty provides via its eleventy.config event. This is likely because the interlinker plugin is using RenderManager in a way its not intended to be used.

Fortunatly the compile function that RenderManager.compile wraps is also exported, however oddly named as String. This PR replaces usage of the render manager with usage of that compile function and should fix the crashing bug reported in #33.

@carbontwelve carbontwelve changed the base branch from main to v1.1.0 May 11, 2024 09:22
@carbontwelve carbontwelve added this to the v1.1.0 milestone May 11, 2024
@carbontwelve carbontwelve changed the title BUGFIX: BUGFIX: Fix crashing bug when embeded file changed while in --watch mode May 11, 2024
@carbontwelve carbontwelve merged commit 7c7a619 into v1.1.0 May 11, 2024
@carbontwelve carbontwelve deleted the patch/v1.1.0/#33 branch May 11, 2024 09:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant