Compare commits

...
9 Commits
Author SHA1 Message Date
rilaxik c8e5bdf375 Merge branch 'dev' into unstable 2024-10-28 15:10:25 +00:00
rilaxik a675114b41 upd core
- changed local shared types package name
2024-10-28 15:10:00 +00:00
rilaxik 54781d50b2 upd core
- changed local rpc to remote dependency
2024-10-28 15:04:39 +00:00
rilaxik de33fe4763 versions bump 2024-10-28 13:20:51 +00:00
rilaxik d3d75b338d v0.2.5 2024-10-28 13:02:24 +00:00
rilaxik 04eb724073 v0.2.4 2024-10-28 12:59:44 +00:00
rilaxik e4950b6c99 Merge remote-tracking branch 'origin/dev' into dev
# Conflicts:
#	lerna.json
#	rpc/package.json
2024-10-28 12:57:58 +00:00
rilaxik 19b1b770f6 v0.2.1 2024-10-28 12:51:53 +00:00
sashagoncharov19 57d80d41d6 Merge pull request 'v0.1.0' (#1) from dev into unstable
Reviewed-on: #1
Reviewed-by: Oleksandr Honcharov <[email protected]>
2024-06-15 13:48:40 +00:00
27 changed files with 6259 additions and 9249 deletions
+2 -2
View File
@@ -11,11 +11,11 @@
"build": "tsup"
},
"dependencies": {
"rage-fw-rpc": "workspace:^"
"@entityseven/rage-fw-rpc": "latest"
},
"peerDependencies": {
"@ragempcommunity/types-cef": "^2.1.8",
"rage-fw-shared-types": "workspace:^"
"@entityseven/rage-fw-shared-types": "workspace:^"
},
"description": "RageFW CEF side",
"keywords": [],
+1 -1
View File
@@ -1,4 +1,4 @@
import { Rpc } from 'rage-fw-rpc'
import { Rpc } from '@entityseven/rage-fw-rpc'
import type {
_CefEventHasArgs,
+2 -2
View File
@@ -1,6 +1,6 @@
import { RageFW_ICustomCefEvent } from 'rage-fw-shared-types'
import { RageFW_ICustomCefEvent } from '@entityseven/rage-fw-shared-types'
export { RageFW_ICustomCefEvent } from 'rage-fw-shared-types'
export { RageFW_ICustomCefEvent } from '@entityseven/rage-fw-shared-types'
/**
* Union of all available cef event names
+2 -2
View File
@@ -1,6 +1,6 @@
import type { RageFW_ICustomClientEvent } from 'rage-fw-shared-types'
import type { RageFW_ICustomClientEvent } from '@entityseven/rage-fw-shared-types'
export type { RageFW_ICustomClientEvent } from 'rage-fw-shared-types'
export type { RageFW_ICustomClientEvent } from '@entityseven/rage-fw-shared-types'
/**
* Union of all available client event names
+2 -2
View File
@@ -1,6 +1,6 @@
import type { RageFW_ICustomServerEvent } from 'rage-fw-shared-types'
import type { RageFW_ICustomServerEvent } from '@entityseven/rage-fw-shared-types'
export type { RageFW_ICustomServerEvent } from 'rage-fw-shared-types'
export type { RageFW_ICustomServerEvent } from '@entityseven/rage-fw-shared-types'
/**
* Union of all available server event names
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "@entityseven/create-rage-fw",
"version": "0.1.0",
"version": "0.1.1",
"bin": {
"rage-fw": "dist/index.js"
},
+1 -1
View File
@@ -2,7 +2,7 @@
To make you life easier while using RageFW we created a basic CLI. At the moment automation we have only works via [pnpm](https://pnpm.io/)
``pnpm create rage-fw@latest``
``pnpm create @entityseven/rage-fw@latest``
## TL;DR
- ``Initialize new project`` - create new template project
+2 -2
View File
@@ -11,11 +11,11 @@
"build": "tsup"
},
"dependencies": {
"rage-fw-rpc": "workspace:^"
"@entityseven/rage-fw-rpc": "latest"
},
"peerDependencies": {
"@ragempcommunity/types-client": "^2.1.8",
"rage-fw-shared-types": "workspace:^"
"@entityseven/rage-fw-shared-types": "workspace:^"
},
"description": "RageFW Client side",
"keywords": [],
+1 -1
View File
@@ -1,4 +1,4 @@
import { Rpc } from 'rage-fw-rpc'
import { Rpc } from '@entityseven/rage-fw-rpc'
import type {
RageFW_ClientArgs,
+2 -2
View File
@@ -1,5 +1,5 @@
import { Rpc } from 'rage-fw-rpc'
import type { RageFW_ICustomClientEvent } from 'rage-fw-shared-types'
import { Rpc } from '@entityseven/rage-fw-rpc'
import type { RageFW_ICustomClientEvent } from '@entityseven/rage-fw-shared-types'
import {
_CefEventHasArgs,
+1 -1
View File
@@ -1,6 +1,6 @@
/// <reference types="@ragempcommunity/types-client" />
import type { RageFW_ICustomCefEvent } from 'rage-fw-shared-types'
import type { RageFW_ICustomCefEvent } from '@entityseven/rage-fw-shared-types'
export type RageFW_CefEvent = keyof RageFW_ICustomCefEvent
+1 -1
View File
@@ -1,6 +1,6 @@
/// <reference types="@ragempcommunity/types-client" />
import type { RageFW_ICustomClientEvent } from 'rage-fw-shared-types'
import type { RageFW_ICustomClientEvent } from '@entityseven/rage-fw-shared-types'
/**
* Union of all available client event names
+1 -1
View File
@@ -3,7 +3,7 @@
import type {
RageFW_ICustomClientEvent,
RageFW_ICustomServerEvent,
} from 'rage-fw-shared-types'
} from '@entityseven/rage-fw-shared-types'
/**
* Union of all available server event names callable from client
+1 -1
View File
@@ -1,5 +1,5 @@
{
"$schema": "node_modules/lerna/schemas/lerna-schema.json",
"version": "0.2.3",
"version": "0.2.5",
"npmClient": "pnpm"
}
+2 -1
View File
@@ -1,7 +1,7 @@
{
"private": true,
"scripts": {
"publish": "pnpm build && lerna publish --force-publish",
"publish": "lerna publish --force-publish",
"build": "lerna run build",
"lint": "eslint --c .eslintrc.yaml --ext .ts client/ server/ shared-types/",
@@ -17,6 +17,7 @@
"@ragempcommunity/types-server": "^2.1.8",
"@typescript-eslint/eslint-plugin": "^7.13.0",
"@typescript-eslint/parser": "^7.13.0",
"@types/node": "^22.8.1",
"eslint": "^8.56.0",
"lerna": "^8.1.3",
"prettier": "^3.3.1",
+6215 -9209
View File
File diff suppressed because it is too large Load Diff
-2
View File
@@ -2,6 +2,4 @@ packages:
- "server"
- "client"
- "cef"
- "rpc"
- "cli"
- "shared-types"
+2 -2
View File
@@ -1,7 +1,7 @@
{
"name": "@entityseven/rage-fw-rpc",
"description": "Rage FW RPC",
"version": "0.2.3",
"version": "0.2.5",
"scripts": {
"build": "tsup",
"start": "npx ./dist create"
@@ -38,5 +38,5 @@
}
],
"license": "MIT",
"gitHead": "74c0215366776f18755c47eaf740518c81245e01"
"gitHead": "04eb7240735c4a0e4855ebabbe8d5b326819fa76"
}
+9 -4
View File
@@ -14,12 +14,17 @@ yarn add rage-fw-rpc
Import installed package and initialize rpc:
```ts
// lib/rpc.js
// lib/rpc.js
import { Rpc } from 'rage-fw-rpc'
export const rpc = new Rpc(/* options */)
import { Rpc } from 'rage-fw-rpc'
export const rpc = new Rpc(/* options */)
```
# Motivation
The idea was to create an extensible package, with various features to simplify the development process and provide as much comfort as possible. It should also be using similar architecture as the framework it was specially built for
Inspired by usage of [rage-rpc](https://github.com/micaww/rage-rpc)
# Features
- Type-safe events via [TS generics](https://www.typescriptlang.org/docs/handbook/2/generics.html), avoiding type wrappers
- Built-in logging options for each environment
@@ -28,7 +33,7 @@ Import installed package and initialize rpc:
- Actual human-readable errors
# Docs
*Extended version with details coming soon*
## [Extended version available here](https://git.entityseven.com/entityseven/rage-framework/wiki/RPC%400.2.5)
## register
Registers a callback function for a specified event
+2 -2
View File
@@ -11,11 +11,11 @@
"build": "tsup"
},
"dependencies": {
"rage-fw-rpc": "workspace:^"
"@entityseven/rage-fw-rpc": "latest"
},
"peerDependencies": {
"@ragempcommunity/types-server": "^2.1.8",
"rage-fw-shared-types": "workspace:^"
"@entityseven/rage-fw-shared-types": "workspace:^"
},
"description": "RageFW Server side",
"keywords": [],
+1 -1
View File
@@ -1,4 +1,4 @@
import { Rpc } from 'rage-fw-rpc'
import { Rpc } from '@entityseven/rage-fw-rpc'
import type {
_CefEventHasArgs,
+2 -2
View File
@@ -1,5 +1,5 @@
import { Rpc } from 'rage-fw-rpc'
import { RageFW_ICustomServerEvent } from 'rage-fw-shared-types'
import { Rpc } from '@entityseven/rage-fw-rpc'
import { RageFW_ICustomServerEvent } from '@entityseven/rage-fw-shared-types'
import { nativeEvents } from '../native.events'
import type {
+1 -1
View File
@@ -1,4 +1,4 @@
import type { RageFW_ICustomCefEvent } from 'rage-fw-shared-types'
import type { RageFW_ICustomCefEvent } from '@entityseven/rage-fw-shared-types'
export type RageFW_CefEvent = keyof RageFW_ICustomCefEvent
+1 -1
View File
@@ -1,6 +1,6 @@
/// <reference types="@ragempcommunity/types-server" />
import type { RageFW_ICustomClientEvent } from 'rage-fw-shared-types'
import type { RageFW_ICustomClientEvent } from '@entityseven/rage-fw-shared-types'
/**
* Union of all available client event names
+2 -2
View File
@@ -3,8 +3,8 @@
import type {
RageFW_ICustomClientEvent,
RageFW_ICustomServerEvent,
} from 'rage-fw-shared-types'
export type { RageFW_ICustomServerEvent } from 'rage-fw-shared-types'
} from '@entityseven/rage-fw-shared-types'
export type { RageFW_ICustomServerEvent } from '@entityseven/rage-fw-shared-types'
/**
* Union of all available server event names
+1 -1
View File
@@ -1,5 +1,5 @@
{
"name": "rage-fw-shared-types",
"name": "@entityseven/rage-fw-shared-types",
"version": "0.1.0",
"types": "types/types/index.d.ts",
"files": [
+1 -1
View File
@@ -1,4 +1,4 @@
declare module 'rage-fw-shared-types' {
declare module '@entityseven/rage-fw-shared-types' {
export interface RageFW_ICustomServerEvent {}
export interface RageFW_ICustomClientEvent {