use(...middleware) {
        const composer = new Composer(...middleware);
        this.handler = concat(this.handler, flatten(composer));
        return composer;
    }
/**
     * Registers some middleware that receives all updates. It is installed by
     * concatenating it to the end of all previously installed middleware.
     *
     * Often, this method is used to install middleware that behaves like a
     * plugin, for example session middleware.
     * ```ts
     * bot.use(session())
     * ```
     *
     * This method returns a new instance of composer. The returned instance can
     * be further extended, and all changes will be regarded here. Confer the
     * [documentation](https://grammy.dev/advanced/middleware.html) on the
     * website if you want to know more about how the middleware system in
     * grammY works, especially when it comes to chaining the method calls
     * (`use( ... ).use( ... ).use( ... )`).
     *
     * @param middleware The middleware to register
     */
Registers some middleware that receives all updates. It is installed by
concatenating it to the end of all previously installed middleware.

Often, this method is used to install middleware that behaves like a
plugin, for example session middleware.

This method returns a new instance of composer. The returned instance can
be further extended, and all changes will be regarded here. Confer the
[documentation] on the
website if you want to know more about how the middleware system in
grammY works, especially when it comes to chaining the method calls
(`use( ...

@param middleware The middleware to register
Registers some middleware that receives all updates . It is installed by concatenating it to the end of all previously installed middleware . Often this method is used to install middleware that behaves like a plugin for example session middleware . This method returns a new instance of composer . The returned instance can be further extended and all changes will be regarded here . Confer the [ documentation ] on the website if you want to know more about how the middleware system in grammY works especially when it comes to chaining the method calls ( ` use ( ... @param middleware The middleware to register
use(...middleware) {
        const composer = new Composer(...middleware);
        this.handler = concat(this.handler, flatten(composer));
        return composer;
    }
use ( ... middleware ) { const composer = new Composer ( ... middleware ) ; this . handler = concat ( this . handler , flatten ( composer ) ) ; return composer ; }
Registers some middleware that receives all updates.
Registers some middleware that receives all updates .