From a11a6cecf47bb1c3c55bc90c033a06d8ee755f0a Mon Sep 17 00:00:00 2001 From: Kevin Levron Date: Sat, 3 Apr 2021 21:43:40 +0200 Subject: [PATCH] move tools (fix rollup) --- src/core/Object3D.js | 5 +++-- src/{tools/index.js => tools.js} | 0 2 files changed, 3 insertions(+), 2 deletions(-) rename src/{tools/index.js => tools.js} (100%) diff --git a/src/core/Object3D.js b/src/core/Object3D.js index 46b29b8..f9f8a31 100644 --- a/src/core/Object3D.js +++ b/src/core/Object3D.js @@ -1,5 +1,5 @@ import { watch } from 'vue'; -import { bindProp } from '../tools/index.js'; +import { bindProp } from '../tools'; export default { name: 'Object3D', @@ -10,11 +10,12 @@ export default { rotation: { type: Object, default: { x: 0, y: 0, z: 0 } }, scale: { type: Object, default: { x: 1, y: 1, z: 1 } }, lookAt: { type: Object, default: null }, + autoRemove: { type: Boolean, default: true }, }, // can't use setup because it will not be used in sub components // setup() {}, unmounted() { - this.removeFromParent(); + if (this.autoRemove) this.removeFromParent(); }, methods: { initObject3D(o3d) { diff --git a/src/tools/index.js b/src/tools.js similarity index 100% rename from src/tools/index.js rename to src/tools.js