MCPcopy
hub / github.com/axios/axios / bodyAsUtf8

Function bodyAsUtf8

tests/smoke/bun/tests/formData.smoke.test.ts:54–56  ·  view source on GitHub ↗
(value: unknown)

Source from the content-addressed store, hash-verified

52};
53
54const bodyAsUtf8 = (value: unknown) => {
55 return Buffer.isBuffer(value) ? value.toString('utf8') : String(value);
56};
57
58describe('form data', () => {
59 test('native Bun FormData body produces multipart/form-data content-type', async () => {

Callers 1

Calls 1

toStringMethod · 0.80

Tested by

no test coverage detected