ne créé un sketch p5 que dans le contexte du browser
This commit is contained in:
parent
4048f92fa4
commit
bfef54523e
|
@ -7,7 +7,9 @@
|
|||
|
||||
export default {
|
||||
mounted() {
|
||||
this.p5Instance = new p5(this.sketch, this.$refs.canvasContainer);
|
||||
if (process.client) {
|
||||
this.p5Instance = new p5(this.sketch, this.$refs.canvasContainer);
|
||||
}
|
||||
},
|
||||
beforeDestroy() {
|
||||
if (this.p5Instance) {
|
||||
|
|
Loading…
Reference in New Issue