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

Make EcmascriptDevChunkContent public to other crates #7160

Merged
merged 1 commit into from
Jan 30, 2024
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.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion crates/turbopack-dev/src/ecmascript/content.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ use super::{
use crate::DevChunkingContext;

#[turbo_tasks::value(serialization = "none")]
pub(super) struct EcmascriptDevChunkContent {
pub struct EcmascriptDevChunkContent {
pub(super) entries: Vc<EcmascriptDevChunkContentEntries>,
pub(super) chunking_context: Vc<DevChunkingContext>,
pub(super) chunk: Vc<EcmascriptDevChunk>,
Expand All @@ -45,6 +45,13 @@ impl EcmascriptDevChunkContent {
}
.cell())
}

#[turbo_tasks::function]
pub async fn entries(
self: Vc<EcmascriptDevChunkContent>,
) -> Result<Vc<EcmascriptDevChunkContentEntries>> {
Ok(self.await?.entries)
}
}

#[turbo_tasks::value_impl]
Expand Down
2 changes: 2 additions & 0 deletions crates/turbopack-dev/src/ecmascript/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,5 @@ pub(crate) mod list;
pub(crate) mod merged;
pub(crate) mod update;
pub(crate) mod version;

pub use content::EcmascriptDevChunkContent;
2 changes: 1 addition & 1 deletion crates/turbopack-dev/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
#![feature(arbitrary_self_types)]

pub(crate) mod chunking_context;
pub(crate) mod ecmascript;
pub mod ecmascript;
pub mod react_refresh;

pub use chunking_context::{DevChunkingContext, DevChunkingContextBuilder};
Expand Down
Loading