Skip to content

Commit 5e24c85

Browse files
author
Sascha Braun
committed
fix compiled version for easier package installation and usage: no more baseUrl / jsx usage in components
1 parent b2589a3 commit 5e24c85

24 files changed

+41
-29
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "vue-threejs-composer",
3-
"version": "0.3.0",
3+
"version": "0.3.1",
44
"main": "build/src/index.js",
55
"typings": "build/src/index.d.ts",
66
"repository": "https://github.com/sascha245/vue-threejs-composer",

src/components/Axes.tsx renamed to src/components/Axes.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,6 @@ export class Axes extends Mixins(
5151
if (!this.m_created) {
5252
return null;
5353
}
54-
return <div>{this.$slots.default}</div>;
54+
return h("div", this.$slots.default);
5555
}
5656
}
File renamed without changes.

src/components/Camera.tsx renamed to src/components/Camera.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,6 @@ export class Camera extends Mixins(ThreeComponent, ThreeSceneComponent) {
7474
if (!this.main || !this.m_created) {
7575
return null;
7676
}
77-
return <div>{this.$slots.default}</div>;
77+
return h("div", this.$slots.default);
7878
}
7979
}

src/components/Fog.tsx renamed to src/components/Fog.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,6 @@ export class Fog extends Mixins(ThreeComponent, ThreeSceneComponent) {
8686
if (!this.m_created) {
8787
return null;
8888
}
89-
return <div />;
89+
return h();
9090
}
9191
}

src/components/Geometry.tsx renamed to src/components/Geometry.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,6 @@ export class Geometry extends Mixins(ThreeComponent, ThreeAssetComponent) {
2121
}
2222

2323
public render(h: any) {
24-
return <div />;
24+
return h();
2525
}
2626
}

src/components/Grid.tsx renamed to src/components/Grid.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import * as THREE from "three";
22
import { Component, Mixins, Prop, Provide } from "vue-property-decorator";
33

4-
import { AssetTypes, GeometryType, MaterialType } from "../types";
54
import { ThreeComponent, ThreeObjectComponent, ThreeSceneComponent } from "./base";
65

76
@Component
@@ -54,6 +53,6 @@ export class Grid extends Mixins(
5453
if (!this.m_created) {
5554
return null;
5655
}
57-
return <div>{this.$slots.default}</div>;
56+
return h("div", this.$slots.default);
5857
}
5958
}

src/components/Group.tsx renamed to src/components/Group.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,6 @@ export class Group extends Mixins(
4646
if (!this.m_created) {
4747
return null;
4848
}
49-
return <div>{this.$slots.default}</div>;
49+
return h("div", this.$slots.default);
5050
}
5151
}

src/components/Light.tsx renamed to src/components/Light.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,6 @@ export class Light extends Mixins(
5050
if (!this.m_created) {
5151
return null;
5252
}
53-
return <div>{this.$slots.default}</div>;
53+
return h("div", this.$slots.default);
5454
}
5555
}

src/components/Material.tsx renamed to src/components/Material.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,6 @@ export class Material extends Mixins(ThreeComponent, ThreeAssetComponent) {
2121
}
2222

2323
public render(h: any) {
24-
return <div />;
24+
return h();
2525
}
2626
}

0 commit comments

Comments
 (0)