Skip to content

lesmemes/worker-speedtest-template

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Speed Test

Worker for measuring download / upload connection speed from the client side, using the Performance Timing API.

index.js is the content of the Workers script.

Note: when running this as your own worker, your latency measurements may differ a small amount from the official version. This is due to the fact that we rely on an internal mechanism to determine the amount of server processing time, which is then subtracted from the measurement.

Wrangler

You can use wrangler to generate a new Cloudflare Workers project based on this template by running the following command from your terminal:

wrangler generate myApp https://github.com/cloudflare/worker-speedtest-template

Before publishing your code you need to edit wrangler.toml file and add your Cloudflare account_id - more information about publishing your code can be found in the documentation.

Once you are ready, you can publish your code by running the following command:

wrangler publish

Serverless

To deploy using serverless add a serverless.yml file.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%