fedify
fedify copied to clipboard
Reduce the duplicated codes in `rendercode.ts`
There are multiple ways to reduce the duplicated codes:
- To separate that patterns and have 3 functions (
render(), renderRequest(), renderResponse()) - To combine two functions and have if conditions to process each type
Request|Response.
Or other ways
Originally posted by @sij411 in https://github.com/fedify-dev/fedify/pull/410#discussion_r2331995381