It seems the library I'm using _does_ have a browser version you can build yourself. I'll look into
It seems the library I'm using does have a browser version you can build yourself. I'll look into how to integrate that
wrangler deploy count in 1MB limit?workers.api.error.script_too_largefetch handler) without awaiting itapp.use('/input/*', bearerAuth({ TOKEN })); I would normally use 'process.env.TOKEN'app scope, then store it in a globalwrangler deployworkers.api.error.script_too_largefetchapp.use('/input/*', bearerAuth({ TOKEN }));appapp.use('/input/*', (c, next) => bearerAuth({ c.env.TOKEN })(c, next));async fn main(req: Request, env: Env, ctx: Context) -> Result<Response> {
let cache = Cache::default();
let path = "http://www.google.com";
let response: Option<Response> = cache.get(path.clone(), false).await?;
console_log!("here!");
match response {
Some(response) => {
let mut resp: Response = Response::ok("Cache hit")?;
Ok(resp)
},
None => {
console_log!("{}", path);
let mut resp = Response::ok("Cache miss")?;
Ok(resp)
}
}
}