| use anyhow::Result; | |
| use turbo_rcstr::RcStr; | |
| use turbo_tasks::Vc; | |
| pub async fn instrumentation_files(page_extensions: Vc<Vec<RcStr>>) -> Result<Vc<Vec<RcStr>>> { | |
| let extensions = page_extensions.await?; | |
| let files = ["instrumentation.", "src/instrumentation."] | |
| .into_iter() | |
| .flat_map(|f| { | |
| extensions | |
| .iter() | |
| .map(move |ext| String::from(f) + ext.as_str()) | |
| .map(RcStr::from) | |
| }) | |
| .collect(); | |
| Ok(Vc::cell(files)) | |
| } | |