Skip to content
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
2 changes: 1 addition & 1 deletion .github/workflows/pr_ci_comment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: PR CI Comment

on:
workflow_run:
workflows: ['build-and-test', 'Generate Stats']
workflows: ['build-and-test']
types: [requested, completed]

permissions:
Expand Down
204 changes: 0 additions & 204 deletions .github/workflows/pull_request_stats.yml

This file was deleted.

1 change: 1 addition & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

27 changes: 16 additions & 11 deletions crates/next-api/src/app.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1090,18 +1090,23 @@ pub fn app_entry_point_to_route(
}
.resolved_cell(),
),
has_action_manifest: true,
},
AppEntrypoint::AppMetadata { page, metadata, .. } => Route::AppRoute {
original_name: page.to_string().into(),
endpoint: ResolvedVc::upcast(
AppEndpoint {
ty: AppEndpointType::Metadata { metadata },
app_project,
page,
}
.resolved_cell(),
),
},
AppEntrypoint::AppMetadata { page, metadata, .. } => {
let has_action_manifest = matches!(metadata, MetadataItem::Dynamic { .. });
Route::AppRoute {
original_name: page.to_string().into(),
endpoint: ResolvedVc::upcast(
AppEndpoint {
ty: AppEndpointType::Metadata { metadata },
app_project,
page,
}
.resolved_cell(),
),
has_action_manifest,
}
}
}
.cell()
}
Expand Down
8 changes: 7 additions & 1 deletion crates/next-api/src/operation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -100,9 +100,14 @@ fn pick_route(entrypoints: OperationVc<Entrypoints>, key: RcStr, route: &Route)
})
.collect(),
),
Route::AppRoute { original_name, .. } => RouteOperation::AppRoute {
Route::AppRoute {
original_name,
has_action_manifest,
..
} => RouteOperation::AppRoute {
original_name: original_name.clone(),
endpoint: pick_endpoint(entrypoints, EndpointSelector::RouteAppRoute(key)),
has_action_manifest: *has_action_manifest,
},
Route::Conflict => RouteOperation::Conflict,
}
Expand Down Expand Up @@ -220,6 +225,7 @@ pub enum RouteOperation {
AppRoute {
original_name: RcStr,
endpoint: OperationVc<OptionEndpoint>,
has_action_manifest: bool,
},
Conflict,
}
Expand Down
1 change: 1 addition & 0 deletions crates/next-api/src/project.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1370,6 +1370,7 @@ impl Project {
Route::AppRoute {
original_name: _,
endpoint,
..
} => {
endpoint_groups.push((
EndpointGroupKey::Route(key.clone()),
Expand Down
1 change: 1 addition & 0 deletions crates/next-api/src/route.rs
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ pub enum Route {
AppRoute {
original_name: RcStr,
endpoint: ResolvedVc<Box<dyn Endpoint>>,
has_action_manifest: bool,
},
Conflict,
}
Expand Down
7 changes: 6 additions & 1 deletion crates/next-api/src/server_actions.rs
Original file line number Diff line number Diff line change
Expand Up @@ -784,7 +784,12 @@ pub async fn map_server_actions(
.map(async |module| {
// TODO: compare module contexts instead?
let layer = match module.ident().await?.layer.as_ref() {
Some(layer) if layer.name() == "app-rsc" || layer.name() == "app-edge-rsc" => {
Some(layer)
if layer.name() == "app-rsc"
|| layer.name() == "app-edge-rsc"
|| layer.name() == "app-route"
|| layer.name() == "app-edge-route" =>
{
ActionLayer::Rsc
}
Some(layer) if layer.name() == "app-client" => ActionLayer::ActionBrowser,
Expand Down
1 change: 1 addition & 0 deletions crates/next-build-test/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,7 @@ pub async fn render_routes(
Route::AppRoute {
original_name: _,
endpoint,
..
} => {
endpoint_write_to_disk_with_apply(endpoint).await?;
}
Expand Down
4 changes: 4 additions & 0 deletions crates/next-napi-bindings/src/next_api/project.rs
Original file line number Diff line number Diff line change
Expand Up @@ -841,6 +841,8 @@ pub struct NapiRoute {

pub pages: Option<Vec<AppPageNapiRoute>>,

pub has_action_manifest: Option<bool>,

// Different representations of the endpoint
pub endpoint: Option<External<ExternalEndpoint>>,
pub html_endpoint: Option<External<ExternalEndpoint>>,
Expand Down Expand Up @@ -895,11 +897,13 @@ impl NapiRoute {
RouteOperation::AppRoute {
original_name,
endpoint,
has_action_manifest,
} => NapiRoute {
pathname,
original_name: Some(original_name),
r#type: "app-route",
endpoint: convert_endpoint(endpoint),
has_action_manifest: Some(has_action_manifest),
..Default::default()
},
RouteOperation::Conflict => NapiRoute {
Expand Down
Loading
Loading