Skip to content

Commit d8d0aed

Browse files
authored
Merge pull request #107 from HippoAR/fix-first-start
clear scene un unmount instead of mount
2 parents eeee6b8 + 361d3a1 commit d8d0aed

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)