Skip to content

Commit 053dc5c

Browse files
refactor(Rest): Rename modules and files to PascalCase convention
Rename all snake_case module files and declarations in Fn/Bundle, Fn/NLS, and Fn/Worker directories to follow PascalCase naming as mandated by CLAUDE.md. This includes: - Bundle: config.rs→Config.rs, builder.rs→Builder.rs, esbuild.rs→ESBuild.rs - NLS: extract.rs→Extract.rs, replace.rs→Replace.rs, bundle.rs→Bundle.rs - Worker: detect.rs→Detect.rs, bootstrap.rs→Bootstrap.rs, compile.rs→Compile.rs Update mod.rs files to use #[path = "..."] attribute syntax with PascalCase module declarations and use statements. Fix internal references in Builder.rs and Compile.rs to use the new module names. This aligns with the project-wide convention that all code follows PascalCase naming for functions, variables, parameters, structs, modules, and file names.
1 parent c9c42a2 commit 053dc5c

12 files changed

Lines changed: 29 additions & 20 deletions

File tree

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ impl BundleBuilder {
140140
/// Build using esbuild wrapper
141141
fn build_with_esbuild(&mut self) -> anyhow::Result<BundleResult> {
142142
// Import and use the esbuild wrapper
143-
let wrapper = super::esbuild::EsbuildWrapper::new();
143+
let wrapper = super::ESBuild::EsbuildWrapper::new();
144144
wrapper.build(&self.config)
145145
}
146146

Source/Fn/Bundle/mod.rs

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,16 @@
55
//! - Optional esbuild integration for complex builds
66
//! - Multi-file compilation support
77
8-
pub mod config;
9-
pub mod builder;
10-
pub mod esbuild;
8+
#[path = "Config.rs"]
9+
pub mod Config;
10+
#[path = "Builder.rs"]
11+
pub mod Builder;
12+
#[path = "ESBuild.rs"]
13+
pub mod ESBuild;
1114

12-
pub use config::BundleConfig;
13-
pub use builder::BundleBuilder;
14-
pub use esbuild::EsbuildWrapper;
15+
pub use Config::BundleConfig;
16+
pub use Builder::BundleBuilder;
17+
pub use ESBuild::EsbuildWrapper;
1518

1619
/// Result of a bundling operation
1720
#[derive(Debug, Clone)]

Source/Fn/NLS/mod.rs

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,16 @@
55
//! - Generation of localization bundle files
66
//! - Replacement of localization keys with actual strings at build time
77
8-
pub mod extract;
9-
pub mod replace;
10-
pub mod bundle;
8+
#[path = "Extract.rs"]
9+
pub mod Extract;
10+
#[path = "Replace.rs"]
11+
pub mod Replace;
12+
#[path = "Bundle.rs"]
13+
pub mod Bundle;
1114

12-
pub use extract::NLSExtractor;
13-
pub use replace::NLSReplacer;
14-
pub use bundle::NLSBundle;
15+
pub use Extract::NLSExtractor;
16+
pub use Replace::NLSReplacer;
17+
pub use Bundle::NLSBundle;
1518

1619
/// Configuration for NLS processing
1720
#[derive(Debug, Clone, Default)]
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ impl WorkerCompiler {
108108
declarations.push_str("// This file is auto-generated - do not edit\n\n");
109109

110110
for worker in workers {
111-
declarations.push_str(&super::bootstrap::generate_worker_declaration(&worker.name));
111+
declarations.push_str(&super::Bootstrap::generate_worker_declaration(&worker.name));
112112
}
113113

114114
declarations

0 commit comments

Comments
 (0)