Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
1.2.0 introduces 3 notable changes to Eleventy Reusable Components:
componentscollection, allowing components to be placed outside Eleventy's input directory.excludeFromProductionconfiguration variable and obscure environment variable check for outputting components during a built; replaced it withoutputboolean for a simpler developer experience.Details:
Debugging and Developer Experience
Introduced a new
src/debug.jsmodule providing granular debug logging utilities for the plugin, including lifecycle logging, component discovery, filter execution, and error reporting. Debugging is controlled via a newdebugoption and environment variables.Integrated debug logging into the component rendering filter (
renderComponent), giving detailed, context-aware feedback during rendering and error scenarios.Component Discovery and Collection
fs/promises.glob, allowing the plugin to find components even outside Eleventy's input directory. This provides more flexibility for project structure.Configuration and Output Control
Replaced the
excludeFromProductionoption with a newoutputboolean, which more clearly controls whether components are written to their own output files or ignored. This change is reflected in the configuration, documentation, and plugin logic.Added a
debugoption to the plugin's configuration, allowing users to easily enable or disable debug output.These changes make the plugin more robust, easier to debug, and more flexible for advanced use cases.