Function create_node_rendered_source

Source
pub fn create_node_rendered_source(
    cwd: Vc<FileSystemPath>,
    env: Vc<Box<dyn ProcessEnv>>,
    base_segments: Vec<BaseSegment>,
    route_type: RouteType,
    server_root: Vc<FileSystemPath>,
    route_match: Vc<Box<dyn RouteMatcher>>,
    pathname: Vc<RcStr>,
    entry: Vc<Box<dyn NodeEntry>>,
    fallback_page: Vc<DevHtmlAsset>,
    render_data: Vc<Value>,
    debug: bool,
) -> Vc<Box<dyn ContentSource>>
Expand description

Creates a content source that renders something in Node.js with the passed entry when it matches a path_regex. Once rendered it serves all assets referenced by the entry that are within the server_root. It needs a temporary directory (intermediate_output_path) to place file for Node.js execution during rendering. The chunking_context should emit to this directory.