diff --git a/CHANGELOG.md b/CHANGELOG.md index d0ddea97ce15..26134f372ac1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,7 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Added - Upgrade: Automatically convert candidates with arbitrary values to their utilities ([#17831](https://github.com/tailwindlabs/tailwindcss/pull/17831), [#17854](https://github.com/tailwindlabs/tailwindcss/pull/17854)) -- Write to log file when using `DEBUG=*` ([#17906](https://github.com/tailwindlabs/tailwindcss/pull/17906)) +- Write to log file when using `DEBUG=*` ([#17906](https://github.com/tailwindlabs/tailwindcss/pull/17906), [#17952](https://github.com/tailwindlabs/tailwindcss/pull/17952)) - Add support for source maps in development ([#17775](https://github.com/tailwindlabs/tailwindcss/pull/17775)) ### Fixed diff --git a/crates/oxide/src/scanner/mod.rs b/crates/oxide/src/scanner/mod.rs index ccdbd231dbc8..05fcd71f19f7 100644 --- a/crates/oxide/src/scanner/mod.rs +++ b/crates/oxide/src/scanner/mod.rs @@ -153,8 +153,24 @@ pub struct Scanner { impl Scanner { pub fn new(sources: Vec) -> Self { + init_tracing(); + + if *SHOULD_TRACE { + event!(tracing::Level::INFO, "Provided sources:"); + for source in &sources { + event!(tracing::Level::INFO, "Source: {:?}", source); + } + } + let sources = Sources::new(public_source_entries_to_private_source_entries(sources)); + if *SHOULD_TRACE { + event!(tracing::Level::INFO, "Optimized sources:"); + for source in sources.iter() { + event!(tracing::Level::INFO, "Source: {:?}", source); + } + } + Self { sources: sources.clone(), walker: create_walker(sources), @@ -163,7 +179,6 @@ impl Scanner { } pub fn scan(&mut self) -> Vec { - init_tracing(); self.scan_sources(); // TODO: performance improvement, bail early if we don't have any changed content