open-index/open-npm huggingface dataset:
npm package: @nano.gift/rpc-core
Description: Core components for type-safe inter-process communication
Latest version: 1.0.5

# @wexond/rpc-core

Core components for type-safe communication.

[![NPM](https://img.shields.io/npm/v/@wexond/rpc-core.svg?style=flat-square)](https://www.npmjs.com/package/@wexond/rpc-core)
[![NPM](https://img.shields.io/npm/dm/@wexond/rpc-core?style=flat-square)](https://www.npmjs.com/package/@wexond/rpc-core)

## Installation

```bash
$ npm install --save @wexond/rpc-core
```

## Usage

This package is meant to provide bare-metal components for building custom type-safe communication for everything.

## Documentation

WIP
npm package: @nano.gift/rpc-electron
Description: Type-safe inter-process communication for Electron
Latest version: 1.0.3

# @wexond/rpc-electron

Type-safe communication between Electron processes.
No more remembering IPC channel names, parameters order and their types.

[![NPM](https://img.shields.io/npm/v/@wexond/rpc-electron.svg?style=flat-square)](https://www.npmjs.com/package/@wexond/rpc-electron)
[![NPM](https://img.shields.io/npm/dm/@wexond/rpc-electron?style=flat-square)](https://www.npmjs.com/package/@wexond/rpc-electron)

## Installation

```bash
$ npm install --save @wexond/rpc-electron @wexond/rpc-core
```

## Quick start

Here's an example of communication from the renderer process to the main process:

- Create a file that is imported in both main and renderer processes, for example `ping-pong.ts`:

```ts
import { RendererToMainChannel } from '@wexond/rpc-electron';

export interface PingPongService {
  ping(): string;
}

export const pingPongChannel = new RendererToMainChannel<PingPongService>(
  'ping-pong',
);
```

- Code for the renderer process:

```ts
import { ipcRenderer } from 'electron';
import { pingPongChannel } from './ping-pong';

const pingPongService = pingPongChannel.getInvoker();

(async () => {
  // Equivalent of |ipcRenderer.invoke|
  console.log(await pingPongService.ping()); // Prints `pong`.
})();
```

- Code for the main process:

```ts
import { RpcMainHandler } from '@wexond/rpc-electron';
import { PingPongService, pingPongChannel } from './ping-pong';

// Equivalent of |ipcMain.handle|
class PingPongHandler implements RpcMainHandler<PingPongService> {
  ping(): string {
    return 'pong';
  }
}

pingPongChannel.getReceiver().handler = new PingPongHandler();
```

### More examples

- [Renderer to Main](examples/renderer-to-main)

## Documentation

WIP
npm package: @nano71/nano-ui
Description: This template should help get you started developing with Vue 3 in Vite.
Latest version: 0.0.0

# nano-ui

This template should help get you started developing with Vue 3 in Vite.

## Recommended IDE Setup

[VSCode](https://code.visualstudio.com/) + [Volar](https://marketplace.visualstudio.com/items?itemName=Vue.volar) (and disable Vetur) + [TypeScript Vue Plugin (Volar)](https://marketplace.visualstudio.com/items?itemName=Vue.vscode-typescript-vue-plugin).

## Customize configuration

See [Vite Configuration Reference](https://vitejs.dev/config/).

## Project Setup

```sh
npm install
```

### Compile and Hot-Reload for Development

```sh
npm run dev
```

### Compile and Minify for Production

```sh
npm run build
```