e280

e280/renraku

⛩️ make beautiful typescript apis

TypeScript
4
0
MIT License

it's always the last argument - by default, renraku will log errors to the console, but you can provide a `LoggerTap` to get verbose logging of everything - here's an example of a `LoggerTap` that logs to a file: ```ts import fs from "node:fs" const logger = new Renraku.LoggerTap({ log(message, meta) { fs.appendFileSync("renraku.log", `${message}\n`) }, error(error, meta) { fs.appendFileSync("renraku.log", `ERROR: ${error.message}\n`) }, }) await new Renraku.Server({rpc: myRpc, tap: logger}) .listen(8000) ``` ### 🍏 transmuters - a transmuter is a function that takes an incoming request and returns a modified request - transmuters are useful for things like authentication, rate limiting, etc - here's an example of a transmuter that adds a `userId` to the request meta: ```ts const addUserId = Renraku.transmuter(async (request, meta) => { const userId = await getUserIdFromRequest(request)

Total donated
Undistributed
Share with your subscribers:

Recipients

How the donated funds are distributed

Support the dependencies of e280/renraku

Account's avatar
logging library
Account's avatar
everyday ts fns for everything
Account's avatar
Simple to use, blazing fast and thoroughly tested websocket client and server for Node.js
Account's avatar
ts/js testing library
Account's avatar
buildy bundly static site generator
Account's avatar
TypeScript definitions for node
Account's avatar
TypeScript definitions for ws
Account's avatar
A simple zero-configuration command-line http server
Account's avatar
TypeScript is a language for application scale JavaScript development

Support the repos that depend on e280/renraku

Top contributors

chase-moskal's profile
chase-moskal
723 contributions

Recent events

Kivach works on the Obyte network, and therefore you can track all donations.

No events yet