From ad52b5eafccb1b179eeffa65a6eeb46767886d53 Mon Sep 17 00:00:00 2001 From: Dominik Picheta Date: Tue, 14 Jul 2026 12:27:45 +0200 Subject: [PATCH] Small improvement to pygments example. --- 13-js-api-pygments/ts/src/index.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/13-js-api-pygments/ts/src/index.ts b/13-js-api-pygments/ts/src/index.ts index b6465c3..060a25c 100644 --- a/13-js-api-pygments/ts/src/index.ts +++ b/13-js-api-pygments/ts/src/index.ts @@ -1,7 +1,7 @@ import templateHtml from './template.html'; interface Env { - PYTHON_RPC: Service; + PYTHON_RPC: HighlighterRpcService; } // Type definition for the Python RPC service methods @@ -12,7 +12,7 @@ interface HighlighterRpcService { export default { async fetch(request, env, ctx): Promise { // Get the RPC stub from the Python worker - const rpc = env.PYTHON_RPC as any as HighlighterRpcService; + const rpc = env.PYTHON_RPC; // Sample code to highlight const sampleCode = `