> For the complete documentation index, see [llms.txt](https://petercheng7788.gitbook.io/developer-note/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://petercheng7788.gitbook.io/developer-note/programming-language/typescript/namespace.md).

# Namespace

* To group multiple related type into the same category which is a namespace

```typescript
interface TestType {
  b:number;
}

declare namespace Test {
  interface Type{
    a:string;
  }
  type B = TestType; 
}
```

```typescript
 const test1 :Test.B = {b:1};
 const test2: Test.Type = {a:1};
```
