|
@@ -7,15 +7,18 @@ import { Header, LoadingIndicator, Text } from '../react/features/base/react';
|
7
|
7
|
|
8
|
8
|
class ExampleCaptureOnMountManually extends Component {
|
9
|
9
|
componentDidMount () {
|
10
|
|
- this.refs.viewShot.capture().then(uri => {
|
|
10
|
+ // captureScreen
|
|
11
|
+ // this.refs.viewShot.capture().then(uri => {
|
|
12
|
+ this.refs.captureScreen.capture().then(uri => {
|
11
|
13
|
console.log("do something with ", uri);
|
12
|
14
|
});
|
13
|
15
|
}
|
14
|
16
|
render() {
|
|
17
|
+ // <ViewShot ref="viewShot" options={{ format: "jpg", quality: 0.9 }}>
|
15
|
18
|
return (
|
16
|
|
- <captureScreen ref="viewShot" options={{ format: "jpg", quality: 0.9 }}>
|
|
19
|
+ <ViewShot ref="captureScreen" options={{ format: "jpg", quality: 0.9 }}>
|
17
|
20
|
<Text>...Something to rasterize...</Text>
|
18
|
|
- </captureScreen>
|
|
21
|
+ </ViewShot>
|
19
|
22
|
);
|
20
|
23
|
}
|
21
|
24
|
}
|