# aframe-quick-ui

> Quick UI in A-Frame, with hand-menus the primary use case. Contains bits of A-Painter.

Latest version **1.0.0** (published 2020-12-10) · MIT license · 0 weekly downloads

## Install

```sh
npm install aframe-quick-ui
pnpm add aframe-quick-ui
yarn add aframe-quick-ui
bun add aframe-quick-ui
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2020-12-10 |
| First published | 2020-12-10 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 3 |
| Unpacked size | 3.7 MB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 5 |
| Author | Erhannis |
| Maintainers | erhannis |
| Keywords | a-frame, menu, menus, ui |

## Links

- npm: https://www.npmjs.com/package/aframe-quick-ui
- Repository: https://github.com/Erhannis/AFrame-Quick-UI
- Homepage: https://github.com/Erhannis/AFrame-Quick-UI#readme
- Issues: https://github.com/Erhannis/AFrame-Quick-UI/issues
- npm.io page: https://npm.io/package/aframe-quick-ui

## Dependencies (3)

- [aframe](https://npm.io/package/aframe.md) ^1.0.4
- [lodash](https://npm.io/package/lodash.md) ^4.17.20
- [aframe-input-mapping-component](https://npm.io/package/aframe-input-mapping-component.md) ^0.1.3

## Alternatives

- [@sindresorhus/slugify](https://npm.io/package/@sindresorhus/slugify.md) — 3.7M weekly downloads
- [solid-js](https://npm.io/package/solid-js.md) — 2.7M weekly downloads
- [expo-glass-effect](https://npm.io/package/expo-glass-effect.md) — 2.5M weekly downloads
- [nanoassert](https://npm.io/package/nanoassert.md) — 780.8K weekly downloads
- [@ffmpeg/ffmpeg](https://npm.io/package/@ffmpeg/ffmpeg.md) — 529.5K weekly downloads

## Recent versions

- 1.0.0 (latest) — 2020-12-10

## README

Package for A-Frame, to easily/quickly make UIs, with the primary use case of on-controller menus in mind.  Some of the code comes from A-Painter, in which context and codebase I originally wrote this code.  There may still be cruft left over, sorry.  It also may be somewhat hacky or non-idiomatic in places; sorry again.  See AFrame-Quick-UI-Test for an example of how to use it.  See also examples/quick-ui.js for examples of how to use different kinds of UI.  See src/components/quick-ui.js (the core of the UI code) for the different layouts etc. available.  (There's a list at the bottom.)  Finally, if the previous are insufficient, here's a run down of how you might make a project that uses this package:

```
npm init
```

```
// Not sure which of these three are really necessary, if any
npm install webpack-dev-server
npm install webpack-cli
npm install webpack
```

```
npm install aframe-quick-ui
```

In package.json, have `scripts` be:
```
  "scripts": {
    "start": "webpack serve"
  },
```

Create ./src/index.js :
```
require("aframe-quick-ui");
```

Create ./index.html :
```
<html>
    <head>
        <script src="main.js"></script>
    </head>
    <body>
        <a-scene>
            <a-entity id="cameraRig">
                <a-entity id="acamera" camera wasd-controls look-controls orbit-controls></a-entity>
                <a-entity id="left-hand"
                    ui-controller="hand: left"
                    ui>
                    <script> 
                        QuickUI.loadUi(({UI}) =>
                            UI.UiButton({text:"A", oncontrollerdown:()=>{console.log("log")}})
                        );
                    </script>
                </a-entity>
                <a-entity id="right-hand"
                    ui-controller="hand: right"
                    ui>
                </a-entity>
            </a-entity>
        </a-scene>    
    </body>
</html>
```

```
npm start
```

Open localhost:8080 in a browser.

License: MIT

-Erhannis

---
_Source: https://npm.io/package/aframe-quick-ui · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
