The code bundle editor is built-in to the EdgeWorkers Management application. You can use this custom tool to edit your EdgeWorkers without having to set up an integrated development environment or use a command line interface.
This tool is useful as a quick editor so you can view, validate, and edit the files in your code bundles.
Log in to Control Center.
Go to ☰ > CDN > EdgeWorkers.
Select the EdgeWorker ID you want to edit.
Select an EdgeWorker version from the EdgeWorker details page to edit an existing EdgeWorker version.
Select the Code Bundle tab.
The files included in the EdgeWorker version appear in the Code bundle editor.
You can also use the code bundle editor to create an EdgeWorker version.
- Review these features to learn how the code bundle editor can help you validate and edit your EdgeWorkers.
|1. View diff||Select two versions of an EdgeWorker ID to compare. Once you've selected the versions you can pick a file from each code bundle to compare in a side-by-side view.|
If a draft version exists for the EdgeWorker ID you can load it in the diff tool. This lets you compare a draft and a saved version.
|2. Navigate files||Navigate between your EdgeWorkers by selecting a folder in the file tree. Open the |
|3. View and edit||View the contents of the file you selected in the file tree. Here you can also view semantic and syntax validation. To save any changes you've made you need to create a new EdgeWorker version. Do this by manually typing in a new EdgeWorker version number.|
|4. View errors||View any validation errors. You cannot save an EdgeWorkers code bundle as a new version if it contains validation errors.|
You can save a code bundle that contains validations errors as a draft.
|5. Save as draft||Create a draft if you want to save your changes and continue editing the code bundle later. You can save a draft even if your code bundle contains validation errors.|
|6. Create new version||The Create new version button remains inactive until you update the EdgeWorker version number and resolve any validation errors.|
Updated 9 months ago