Skip to content

Commit 361d3a1

Browse files
committed
clear scene un unmount instead of mount
fixes #100
1 parent 5d00b87 commit 361d3a1

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

ARKit.js

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,15 +36,14 @@ class ARKit extends Component {
3636
reason: 0,
3737
floor: null,
3838
};
39-
componentWillMount() {
40-
ARKitManager.clearScene();
41-
}
39+
4240
componentDidMount() {
4341
ARKitManager.resume();
4442
}
4543

4644
componentWillUnmount() {
4745
ARKitManager.pause();
46+
ARKitManager.clearScene();
4847
}
4948

5049
render(AR = RCTARKit) {

0 commit comments

Comments
 (0)