]> git.proxmox.com Git - mirror_novnc.git/blame - docs/LIBRARY.md
Remove unnecessary constructor parameter from Cursor
[mirror_novnc.git] / docs / LIBRARY.md
CommitLineData
91e811f7
PO
1# Using the noVNC JavaScript library
2
3This document describes how to make use of the noVNC JavaScript library for
4integration in your own VNC client application. If you wish to embed the more
5complete noVNC application with its included user interface then please see
6our [embedding documentation](EMBEDDING.md).
7
8## API
9
10The API of noVNC consists of a single object called `RFB`. The formal
11documentation for that object can be found in our [API documentation](API.md).
12
13## Example
14
15noVNC includes a small example application called `vnc_lite.html`. This does
16not make use of all the features of noVNC, but is a good start to see how to
17do things.
18
19## Conversion of Modules
20
21noVNC is written using ECMAScript 6 modules. Many of the major browsers support
22these modules natively, but not all. They are also not supported by Node.js. To
23use noVNC in these places the library must first be converted.
24
25Fortunately noVNC includes a script to handle this conversion. Please follow
26the following steps:
27
28 1. Install Node.js
29 2. Run `npm install` in the noVNC directory
30 3. Run `./utils/use_require.js --as <module format>`
31
32Several module formats are available. Please run
33`./utils/use_require.js --help` to see them all.
34
35The result of the conversion is available in the `lib/` directory.