8000 fix: adk web not working on some env for windows, fixes https://githu… · sonnet115/adk-python@daac8ce · GitHub
[go: up one dir, main page]

10000
Skip to content

Commit daac8ce

Browse files
wyf7107copybara-github
authored andcommitted
fix: adk web not working on some env for windows, fixes google/adk-web#34
PiperOrigin-RevId: 765271751
1 parent 6506302 commit daac8ce

File tree

1 file changed

+5
-0
lines changed

src/google/adk/cli/fast_api.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -858,6 +858,11 @@ async def _get_runner_async(app_name: str) -> Runner:
858858
return runner
859859

860860
if web:
861+
import mimetypes
862+
863+
mimetypes.add_type("application/javascript", ".js", True)
864+
mimetypes.add_type("text/javascript", ".js", True)
865+
861866
BASE_DIR = Path(__file__).parent.resolve()
862867
ANGULAR_DIST_PATH = BASE_DIR / "browser"
863868

0 commit comments

Comments
 (0)
0