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

chore(swc_core): add more sub module into swc_core #6548

Merged
merged 3 commits into from Nov 30, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 3 additions & 0 deletions crates/swc_core/Cargo.toml
Expand Up @@ -99,11 +99,13 @@ ecma_utils = ["__utils", "__common"]

# Enable swc_ecma_transforms base features
ecma_transforms = ["__ecma_transforms"]
ecma_transforms_compat = ["__ecma_transforms", "swc_ecma_transforms_compat"]
ecma_transforms_module = ["__ecma_transforms", "swc_ecma_transforms_module"]
ecma_transforms_optimization = [
"__ecma_transforms",
"swc_ecma_transforms_optimization",
]
ecma_transforms_proposal = ["__ecma_transforms", "swc_ecma_transforms_proposal"]
ecma_transforms_react = ["__ecma_transforms", "swc_ecma_transforms_react"]
ecma_transforms_typescript = [
"__ecma_transforms",
Expand Down Expand Up @@ -340,6 +342,7 @@ swc_ecma_parser = { optional = true, version = "0.123.0", path
swc_ecma_preset_env = { optional = true, version = "0.175.0", path = "../swc_ecma_preset_env" }
swc_ecma_quote_macros = { optional = true, version = "0.34.0", path = "../swc_ecma_quote_macros" }
swc_ecma_transforms_base = { optional = true, version = "0.112.0", path = "../swc_ecma_transforms_base" }
swc_ecma_transforms_compat = { optional = true, version = "0.137.0", path = "../swc_ecma_transforms_compat" }
swc_ecma_transforms_module = { optional = true, version = "0.154.0", path = "../swc_ecma_transforms_module" }
swc_ecma_transforms_optimization = { optional = true, version = "0.168.0", path = "../swc_ecma_transforms_optimization" }
swc_ecma_transforms_proposal = { optional = true, version = "0.145.0", path = "../swc_ecma_transforms_proposal" }
Expand Down
10 changes: 10 additions & 0 deletions crates/swc_core/src/lib.rs
Expand Up @@ -61,6 +61,16 @@ pub mod ecma {
pub mod module {
pub use swc_ecma_transforms_module::*;
}
#[cfg(feature = "ecma_transforms_proposal")]
#[cfg_attr(docsrs, doc(cfg(feature = "transforms_proposal")))]
pub mod proposal {
pub use swc_ecma_transforms_proposal::*;
}
#[cfg(feature = "ecma_transforms_compat")]
#[cfg_attr(docsrs, doc(cfg(feature = "transforms_compat")))]
pub mod compat {
pub use swc_ecma_transforms_compat::*;
}
#[cfg(feature = "__testing_transform")]
#[cfg_attr(docsrs, doc(cfg(feature = "__testing_transform")))]
pub mod testing {
Expand Down