> For the complete documentation index, see [llms.txt](https://javascriptuse.gitbook.io/advanced/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://javascriptuse.gitbook.io/advanced/type-script/mini-website-with-typescript-compile-file-ts-chay-thoi-gian-thuc-ok/khong-hieu-tai-sao-khi-su-dung-nodemon.json-no-moi-chay-duoc/mini-website-with-typescript-html-.d.ts-cau-hinh-nodemon.json-ok.md).

# Mini Website with TypeScript, html, .d.ts, cấu hình nodemon.json (ok)

<figure><img src="/files/JZUqqGAxjyFhYs3CjnpJ" alt=""><figcaption></figcaption></figure>

package.json

```json
{
  "name": "ts_browser_test___",
  "version": "1.0.0",
  "description": "",
  "main": "index.js",
  "scripts": {
    "start": "parcel index.html",
    "build": "parcel build index.html"
  },
  "keywords": [],
  "author": "",
  "license": "ISC",
  "devDependencies": {
    "parcel-bundler": "^1.12.5",
    "typescript": "^5.3.3"
  }
}

```

tsconfig.json

```typescript
{
  "compilerOptions": {
    "target": "es2016",
    "lib": [
      "es2016",
      "DOM"
    ],
    "module": "commonjs",
    "rootDir": "src",
    "sourceMap": true,
    "outDir": "build",
    "esModuleInterop": true,
    "forceConsistentCasingInFileNames": true,
    "strict": true,
    "skipLibCheck": true
  }
}
```

index.html

```html
<!DOCTYPE html>
<html>
  <head>
    <meta charset="UTF-8" />
    <title>bobbyhadz.com</title>
    <style>
      #container {
        background-color: lime;
        width: 450px;
        height: 450px;
      }
    </style>
  </head>
  <body>
    <div id="container">
      <h2>bobbyhadz.com</h2>
    </div>
    <script src="./src/index.ts"></script>
  </body>
</html>

```

src\index.ts

```typescript
window.example = 'bobbyhadz.com';
console.log(window.example);
```

src\types\index.d.ts

```typescript
export { };
declare global {
  interface Window {
    example: any;
  }
}
```

<figure><img src="/files/hzHUnSFD1uRSuxfhRIVn" alt=""><figcaption></figcaption></figure>

{% file src="/files/YwwCP2w56ZNJvJezkJLU" %}
