Home / Function/ plugin() — fastify Function Reference

plugin() — fastify Function Reference

Architecture documentation for the plugin() function in type-provider.test-d.ts from the fastify codebase.

Entity Profile

Dependency Diagram

graph TD
  7223f605_fe98_ddf8_7db4_100215acbaeb["plugin()"]
  ef34a0e1_9914_a601_dd6e_13c7d2150b71["type-provider.test-d.ts"]
  7223f605_fe98_ddf8_7db4_100215acbaeb -->|defined in| ef34a0e1_9914_a601_dd6e_13c7d2150b71
  style 7223f605_fe98_ddf8_7db4_100215acbaeb fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

test/types/type-provider.test-d.ts lines 1114–1124

function plugin<T extends FastifyInstance> (instance: T) {
  expectAssignable(instance.withTypeProvider<AuxiliaryPluginProvider>().get(
    '/',
    {
      schema: { body: null }
    },
    (req) => {
      expectType<'plugin-auxiliary'>(req.body)
    }
  ))
}

Domain

Subdomains

Frequently Asked Questions

What does plugin() do?
plugin() is a function in the fastify codebase, defined in test/types/type-provider.test-d.ts.
Where is plugin() defined?
plugin() is defined in test/types/type-provider.test-d.ts at line 1114.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free