Unverified Commit 76c43b7d authored by Tobias Koppers's avatar Tobias Koppers Committed by GitHub

fix transform of files ending with d (#63367)

### What?

fixed `"use client"` in files ending with `d`...

### Why?

### How?


Closes PACK-2753
parent 3b6b04ae
......@@ -221,7 +221,7 @@ pub async fn parse_segment_config_from_source(
// Don't try parsing if it's not a javascript file, otherwise it will emit an
// issue causing the build to "fail".
if path.path.ends_with("d.ts")
if path.path.ends_with(".d.ts")
|| !(path.path.ends_with(".js")
|| path.path.ends_with(".jsx")
|| path.path.ends_with(".ts")
......
......@@ -71,7 +71,7 @@ fn match_js_extension(enable_mdx_rs: bool) -> Vec<ModuleRuleCondition> {
ModuleRuleCondition::All(vec![
ModuleRuleCondition::ResourcePathEndsWith(".ts".to_string()),
ModuleRuleCondition::Not(Box::new(ModuleRuleCondition::ResourcePathEndsWith(
"d.ts".to_string(),
".d.ts".to_string(),
))),
]),
ModuleRuleCondition::ResourcePathEndsWith(".tsx".to_string()),
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment