Hello I want to make a plugin system and decerators like how the fastify framework does but I cant get types working for the decerators and the overall system for plugins to work.
some docs about how it works in fastify
https://fastify.dev/docs/latest/Reference/Plugins/
and then the system in typescript for plugins
https://fastify.dev/docs/latest/Reference/TypeScript#plugins
you will see how the plugins can add vars, class, functions, objects, etc to the main instance of the program using fastify.decorate("name", thing) and then they add the type
if someone can help me code a system like this i would be super happy
Plugins
TypeScript