Fastify/5/Listen Arg Transformation

/icons/calendar.svg

Last update

Dec 17, 2024

This codemod turns fastify.listen(8000) into fastify.listen({ port: 8000 }), reflecting the highlights of the migration from the old listen method signature to the new object-based approach in Fastify v5.

Before

fastify.listen(8000);

After

fastify.listen({
port: 8000,
});

Build custom codemods

Use AI-powered codemod studio and automate undifferentiated tasks for yourself, colleagues or the community

background illustrationGet Started Now