)]}'
{
  "commit": "176de79e7d3d6a894babccc5d8dc8bb9bf133828",
  "tree": "bec096858c74a6a51774ccff398a613c7944c2db",
  "parents": [
    "d9f1337ec3317a60df50d8ba4eefb448473d62fa"
  ],
  "author": {
    "name": "Philip Zeyliger",
    "email": "philip.zeyliger@gmail.com",
    "time": "Mon Apr 21 12:25:18 2025 -0700"
  },
  "committer": {
    "name": "Philip Zeyliger",
    "email": "philip.zeyliger@gmail.com",
    "time": "Mon Apr 21 15:35:02 2025 -0700"
  },
  "message": "sketch: compress JS and CSS\n\nWe noticed that our JS bundles weren\u0027t compressed; let\u0027s compress them.\nSketch did most of the work here itself, but there\u0027s some nonsense\naround the fact that we pass a zip.Reader around, which can\u0027t seek.\nWe\u0027re probably doing more work than strictly necessary on the server side.\n\nAdd gzip compression for JS and source map files in esbuild\n\n- Added compression for .js and .js.map files in the esbuild Build() function\n- Gzipped files are created alongside the originals with .gz extension\n- This allows for compressed asset serving when supported by clients\n\nCo-Authored-By: sketch\n\nAdd support for serving pre-compressed JS and source map files\n\n- Created a custom HTTP handler for /static/ path\n- Handler checks if requested JS/JS.map files have gzipped versions\n- Serves gzipped files with proper Content-Encoding headers when available\n- Falls back to original files when compressed versions are not found\n- Client support for gzip encoding is verified through Accept-Encoding header\n\nCo-Authored-By: sketch\n\nExtend gzip compression to include CSS files\n\n- Added CSS files to the compression list alongside JS and source map files\n- Added debug output to show which files are being compressed\n- Updated error messages to reflect the inclusion of CSS files\n\nCo-Authored-By: sketch\n\nFix variable naming in Accept-Encoding header processing\n\n- Renamed \u0027header\u0027 variable to \u0027encoding\u0027 for better semantics when processing Accept-Encoding headers\n- Addresses gopls check issue in compressed file handler\n\nCo-Authored-By: sketch\n\nSimplify Accept-Encoding header processing\n\n- Simplified check for gzip support using strings.Contains()\n- More efficient approach than splitting and iterating\n- Addresses gopls efficiency recommendation\n\nCo-Authored-By: sketch\n\nExtract compressed file handler to separate package\n\n- Created a new package loop/server/gzhandler\n- Moved compressedFileHandler implementation to the new package\n- Renamed to Handler for better Go idioms\n- Updated loophttp.go to use the new package\n- Improved modularity and separation of concerns\n\nCo-Authored-By: sketch\n\nEnhance gzhandler and add test coverage\n\n- Updated gzhandler to handle all files except .gz files\n- Added comprehensive test suite for gzhandler\n- Removed debug print from esbuild.go\n- Tests different file types, browsers with and without gzip support\n- Tests directory handling\n\nCo-Authored-By: sketch\n\nFix \u0027seeker can\u0027t seek\u0027 error in gzhandler\n\n- Changed approach to read gzipped file into memory before serving\n- Avoids io.Seeker interface requirement for http.ServeContent\n- Fixes 500 error when serving compressed JavaScript files\n- Added missing io import\n\nCo-Authored-By: sketch\n",
  "tree_diff": [
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "3109ea20930d61a18ea7d4e8c9cae233fc0a575a",
      "new_mode": 33188,
      "new_path": "loop/server/gzhandler/gzhandler.go"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "958f8ab6d7f9534095a00636b9ed673e3e059681",
      "new_mode": 33188,
      "new_path": "loop/server/gzhandler/gzhandler_test.go"
    },
    {
      "type": "modify",
      "old_id": "0253f6dd7a10d831bc2a57194d6f93b8e54d03bd",
      "old_mode": 33188,
      "old_path": "loop/server/loophttp.go",
      "new_id": "0660357f09b6a68a662d0df0ea17ddade48360da",
      "new_mode": 33188,
      "new_path": "loop/server/loophttp.go"
    },
    {
      "type": "modify",
      "old_id": "d4af63635002fa49b846786060ece1f36750a206",
      "old_mode": 33188,
      "old_path": "loop/webui/esbuild.go",
      "new_id": "03c745e2a3da36552e01cf34ba70045fdf171530",
      "new_mode": 33188,
      "new_path": "loop/webui/esbuild.go"
    }
  ]
}
