# Class SubAppServerRenderPipeline

The server side rendering pipeline for a subapp

The pipeline involves preparing the data (which is async), and then rendering the component to string or stream, which can be sync or async.

It's also possible that the subapp only wants the data but not actually rendering the component.

- load will setup this and kick off prepare data
- start will await for prepare data and render, and inject result into HTML

#### Implements

- SubAppRenderPipeline

- Defined in node/server-render-pipeline.ts:42

#####
Index

### Constructors

constructor

### Properties

_mount
_reload
_unmount
framework?
options
outputSpot?
prepResult?
preparePromise?
ssrData?
startTime?
INITIAL_STATE_TAG_ID

### Methods

executeRender
getPrepResult
isPrepared
start
startPrepare
waitForPrepare

## Constructors

### constructor

- new SubAppServerRenderPipeline(data): SubAppServerRenderPipeline

- #### Parameters

  - data: SubAppSSRData

  #### Returns SubAppServerRenderPipeline

  - Defined in node/server-render-pipeline.ts:57

## Properties

### _mount

_mount: ((info) => void)

For HMR: a component mount itself to the subapp/pipeline - empty filler

#### Type declaration

- - (info): void

  - #### Parameters

    - info: SubAppMountInfo

    #### Returns void

Implementation of SubAppRenderPipeline._mount

- Defined in node/server-render-pipeline.ts:166

### _reload

_reload: (() => Promise<any>)

Hot module reload (HMR) support - empty filler

#### Type declaration

- - (): Promise<any>

  - #### Returns Promise<any>

Implementation of SubAppRenderPipeline._reload

- Defined in node/server-render-pipeline.ts:164

### _unmount

_unmount: ((info) => void)

For HMR: a component unmount itself from the subapp/pipeline - empty filler

#### Type declaration

- - (info): void

  - #### Parameters

    - info: SubAppMountInfo

    #### Returns void

Implementation of SubAppRenderPipeline._unmount

- Defined in node/server-render-pipeline.ts:168

### `Optional` framework

framework?: ServerFrameworkLib

- Defined in node/server-render-pipeline.ts:48

### options

options: LoadSubAppOptions

options for rendering the subapp into HTML page

- Defined in node/server-render-pipeline.ts:44

### `Optional` outputSpot

outputSpot?: any

spot in HTML output to inject the result from SSR

- Defined in node/server-render-pipeline.ts:51

### `Optional` prepResult

prepResult?: SubAppFeatureResult

data from prepareData

- Defined in node/server-render-pipeline.ts:53

### `Optional` preparePromise

preparePromise?: Promise<unknown>

the promise for subapp's data prepare

- Defined in node/server-render-pipeline.ts:46

### `Optional` ssrData

ssrData?: SubAppSSRData

- Defined in node/server-render-pipeline.ts:47

### `Optional` startTime

startTime?: number

- Defined in node/server-render-pipeline.ts:49

### `Static` INITIAL_STATE_TAG_ID

INITIAL_STATE_TAG_ID: number = 0

- Defined in node/server-render-pipeline.ts:55

## Methods

### executeRender

- executeRender(): void

- #### Returns void

  Implementation of SubAppRenderPipeline.executeRender

  - Defined in node/server-render-pipeline.ts:113

### getPrepResult

- getPrepResult(): SubAppFeatureResult

- #### Returns SubAppFeatureResult

  Implementation of SubAppRenderPipeline.getPrepResult

  - Defined in node/server-render-pipeline.ts:105

### isPrepared

- isPrepared(): boolean

- #### Returns boolean

  Implementation of SubAppRenderPipeline.isPrepared

  - Defined in node/server-render-pipeline.ts:109

### start

- start(_reload?): Promise<any>

- #### Parameters

  - `Optional` _reload: boolean

  #### Returns Promise<any>

  Implementation of SubAppRenderPipeline.start

  - Defined in node/server-render-pipeline.ts:66

### startPrepare

- startPrepare(): void

- start to run through all the subapp's features to prepare data for calling renderToString

  #### Returns void

  Implementation of SubAppRenderPipeline.startPrepare

  - Defined in node/server-render-pipeline.ts:71

### waitForPrepare

- waitForPrepare(): Promise<SubAppFeatureResult>

- #### Returns Promise<SubAppFeatureResult>

  Implementation of SubAppRenderPipeline.waitForPrepare

  - Defined in node/server-render-pipeline.ts:99