diff --git a/README.md b/README.md index b779b27..952779c 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,7 @@ # gRPCity ![build-status](https://github.com/chakhsu/grpcity/actions/workflows/build.yml/badge.svg) ![npm](https://img.shields.io/npm/v/grpcity) ![license](https://img.shields.io/npm/l/grpcity) +grpcity logo + [English](./README.md) | [简体中文](./README_CN.md) ## Introduction @@ -69,10 +71,10 @@ message Message { Next, create `loader.js` and write the following code in it: ```js -import GrpcLoader from 'grpcity' +import { ProtoLoader } from 'grpcity' import path from 'node:path' -export default new GrpcLoader({ +export default new ProtoLoader({ location: path.join(__dirname, './'), files: ['greeter.proto'] }) @@ -131,7 +133,7 @@ const start = async (addr) => { start('127.0.0.1:9099') ``` -Once the programming work is completed, you can start it by running: +Once the programming work is completed, you can start it in the terminal by running: ```sh node ./server.js diff --git a/README_CN.md b/README_CN.md index c372774..8751201 100644 --- a/README_CN.md +++ b/README_CN.md @@ -1,5 +1,7 @@ # gRPCity ![build-status](https://github.com/chakhsu/grpcity/actions/workflows/build.yml/badge.svg) ![npm](https://img.shields.io/npm/v/grpcity) ![license](https://img.shields.io/npm/l/grpcity) +grpcity logo + [English](./README.md) | [简体中文](./README_CN.md) ## 介绍 @@ -64,10 +66,10 @@ message Message { 然后,创建`loader.js`, 编写下面的代码到其中: ```js -import GrpcLoader from 'grpcity' +import { ProtoLoader } from 'grpcity' import path from 'node:path' -export default new GrpcLoader({ +export default new ProtoLoader({ location: path.join(__dirname, './'), files: ['greeter.proto'] }) @@ -126,7 +128,7 @@ const start = async (addr) => { start('127.0.0.1:9099') ``` -完成编程工作之后,就可以通过下面的命令启动~ +完成编程工作之后,就可以在终端里执行下面命令进行启动~ ```sh node ./server.js diff --git a/docs/grpcity-logo-white.svg b/docs/grpcity-logo-white.svg new file mode 100644 index 0000000..32ed5cd --- /dev/null +++ b/docs/grpcity-logo-white.svg @@ -0,0 +1,59 @@ + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/docs/grpcity-logo.svg b/docs/grpcity-logo.svg new file mode 100644 index 0000000..b54ef56 --- /dev/null +++ b/docs/grpcity-logo.svg @@ -0,0 +1,59 @@ + + + + + + + + + + + + + + + + + + \ No newline at end of file