Giter Site home page Giter Site logo

i-http-rpc's Introduction

i-http-rpc

一个方便不同项目合作的带智能提示的 http rpc 约定

Install

npm i i-http-rpc

Usage

源文件 template 文件夹中有使用示例。
默认使用约定为:服务器的消息处理为 文件名-方法名的形式,
智能提示文件httpRpc_projectName.ts由接口提供者,即server方编写,里面就是服务器的所有接口文档。
客户端调用let res = await client.rpc().testFile.add(1, 2),服务器将会在testFile.ts文件中的add方法处收到并处理。
当项目间需要调用接口时,只需要把接口提示文件发给他,便可以方便的进行调用了。
框架提供了自定义的功能,开发者可以按需修改。

i-http-rpc's People

Contributors

ahuangege avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.