2018-04-05 19:50:52 +00:00
|
|
|
Rendering a real `Whisper.MessageView` using `<util.ConversationContext />` and
|
2018-04-03 22:56:12 +00:00
|
|
|
`<util.BackboneWrapper />`.
|
|
|
|
|
|
|
|
```jsx
|
|
|
|
const model = new Whisper.Message({
|
|
|
|
type: 'outgoing',
|
|
|
|
body: 'text',
|
|
|
|
sent_at: Date.now() - 5000,
|
|
|
|
})
|
|
|
|
const View = Whisper.MessageView;
|
|
|
|
const options = {
|
|
|
|
model,
|
|
|
|
};
|
2018-04-05 19:41:48 +00:00
|
|
|
<util.ConversationContext theme={util.theme}>
|
2018-04-03 22:56:12 +00:00
|
|
|
<util.BackboneWrapper
|
|
|
|
View={View}
|
|
|
|
options={options}
|
|
|
|
/>
|
2018-04-05 19:41:48 +00:00
|
|
|
</util.ConversationContext>
|
2018-04-03 22:56:12 +00:00
|
|
|
```
|