# load()

Loads the room inside the iframe. Typically you need to invoke this method only once. The `props` param is optional.

The **load()** method is the delayed form of initialization - you first call **createControl** of the SDK and then you can load the room later based on your application needs.

{% hint style="info" %}
Read more about SDK initialization process in the [DigitalSambaEmbedded class](/reference/sdk/digitalsambaembedded-class.md) section
{% endhint %}

#### InstanceProperties signature

* `frameAttributes` - list of attributes to be applied to the target iframe
* `reportErrors` - boolean, false by default. Whether to report misconfiguration or runtime errors to console

#### Sample code -> it will put a 5px red border around the iframe (using the html style attribute):

```javascript
const initOptions = {team: 'myTeamNameHere', room: 'myRoomNameHere'};
const sambaFrame = DigitalSambaEmbedded.createControl(initOptions);
//..................................................................

//Some time later load the room
sambaFrame.load({
  frameAttributes: {style: "border: 5px solid red"},
  reportErrors: false
});
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.digitalsamba.com/reference/sdk/methods/load.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
