JavaScript utilities for use with the Ninchat API.
Points of interest:
-
src/ninchatclient/
contains Go sources for NinchatClient, a library for accessingapi.ninchat.com
from a web browser, Node.js or React Native. It is a thin wrapper over theninchat-go
package (referenced as a Git submodule). -
gen/ninchatclient.js
contains JavaScript sources generated with GopherJS. Regenerate withmake
(requires Go). The latest stable version is available athttps://ninchat.com/js/ninchatclient.js
andhttps://ninchat.com/js/ninchatclient.min.js
. -
docs/ninchatclient.md
contains API documentation. -
example/client-test.js
demonstrates usage.
NinchatClient supports IE8 and later, but the code generated by GopherJS requires ES5 and typed array shims. When WebSocket transport is not available, NinchatClient doesn't actually use the typed arrays, so stubs are enough.