Skip to content

Commit 4c930e6

Browse files
committed
add README
1 parent db572cf commit 4c930e6

File tree

2 files changed

+34
-0
lines changed

2 files changed

+34
-0
lines changed

README.md

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
# aframe-htmltexture-component
2+
3+
[![Version](https://img.shields.io/npm/v/aframe-htmltexture-component.svg)](https://preview.npmjs.com/package/aframe-htmltexture-component)
4+
[![Repo on GitHub](https://img.shields.io/badge/repo-GitHub-3D76C2.svg)](https://github.com/scenevr/aframe-htmltexture-component)
5+
6+
HTML Texture component for A-Frame VR.
7+
8+
![](./examples/example.png)
9+
10+
## Usage
11+
12+
Import `aframe-htmltexture-component` and `aframe-draw-component`
13+
14+
```js
15+
import 'aframe-draw-component'
16+
import 'aframe-htmltexture-component'
17+
```
18+
19+
In your template :
20+
21+
```html
22+
<div id="hello">
23+
Hello <b>World !</b>
24+
</div>
25+
26+
<a-entity geometry="primitive: box" htmltexture="asset: #hello" position="0 2 -4" draw="width: 128; height: 512;"></a-entity>
27+
```
28+
29+
## See also
30+
31+
- [aframe-draw-component](https://github.com/maxkrieger/aframe-draw-component)
32+
- [aframe-html-shader](https://github.com/mayognaise/aframe-html-shader)
33+
34+

examples/example.png

36.9 KB
Loading

0 commit comments

Comments
 (0)