title: TypeScript | Namespace 'global.Express' has no exported member 'ICustomRequest'
body: <p>I'm migrating a existing project to it. I created a file called yelp-camp.d.ts:</p>
  
  <pre><code>declare namespace NodeJS {
    export interface ProcessEnv {
      MONGO_URI: string;
      GOOGLE_API: string;
      SECRET_KEY: string;
    }
  }
  
  declare namespace Express {
    export interface ICustomRequestUser extends Express.User{
      _id: string;
      username: string;
      isAdmin: boolean;
    }
    export interface ICustomRequest&lt;T&gt; extends Express.Request {
      body: T;
      params: {
        id: string;
        comment_id: string;
      };
    }
  }
  </code></pre>
  
  <p>And on my controllers I use this ICustomRequest interface, like this:</p>
  
  <pre><code>async create(req: Express.ICustomRequest&lt;ICampground&gt;, res: Response) {
      try {
        const data = await this.geocoder.geocode(req.body.location);
  
        const imageUrl = await upload(req.file);
  
        const newCampground = {
          name: req.body.name,
          image: imageUrl,
          description: req.body.description,
          author: {
            id: req.user!._id,
            username: req.user!.username,
          },
          price: req.body.price,
          location: data[0].formattedAddress!,
          lat: data[0].latitude!,
          lng: data[0].longitude!,
        };
  
        await CampgroundModel.create(newCampground);
  
        return res.status(201).json(newCampground);
      } catch (err) {
        console.log(err.message);
        return res.status(401).json({});
      }
    }
  </code></pre>
  
  <p>However I'm getting this error: Namespace 'global.Express' has no exported member 'ICustomRequest'. How can I solve this?</p>