@kirejs/fivem 0.0.0-stage → 0.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +16 -2
- package/dist/cjs/index.js +5663 -0
- package/dist/cjs/package.json +1 -0
- package/dist/esm/index.js +5630 -0
- package/dist/esm/package.json +1 -0
- package/dist/types/index.d.ts +43 -0
- package/dist/types/types.d.ts +24 -0
- package/package.json +31 -3
package/README.md
CHANGED
|
@@ -1,3 +1,17 @@
|
|
|
1
|
-
#
|
|
1
|
+
# @kirejs/fivem
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
FiveM NUI integration — render NUI pages and answer updates via RegisterNuiCallback (no HTTP server).
|
|
4
|
+
|
|
5
|
+
```bash
|
|
6
|
+
npm install @kirejs/fivem
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
```ts
|
|
10
|
+
import { kireFivem } from "@kirejs/fivem";
|
|
11
|
+
|
|
12
|
+
const fivem = kireFivem({ views, wire: { instance: wire } });
|
|
13
|
+
RegisterNuiCallback(fivem.path, fivem.handler);
|
|
14
|
+
SendNuiMessage(JSON.stringify({ type: "page", html: await fivem.render("counter") }));
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
> **AI agents:** see [AGENT.md](./AGENT.md) for a focused guide, and the repository root `CLAUDE.md`.
|