Go to the course and have any video up. The following code relies on the right sidebar to be visible to uncheck all your progress.
You can do this with ctrl+shift+j
and making sure the console
tab is selected for chrome/brave
For FireFox, use ctrl+shift+i
and select the console
tab
Copy and paste this code in the console
Hit the enter
key to run
// Stores all unexpanded section headers, and clicks on the unexpanded section headers to expand them
const sectionEl = document.querySelectorAll("section[data-purpose='sidebar'] div.udlite-btn");
sectionEl.forEach((section) => {
const isClosed = section.parentElement.querySelector("span").getAttribute("data-checked") !== "checked"
if (isClosed) section.click()
});
// Stores all checkboxes on the page, and clicks on any checkboxes on that currently checked
const checkboxes = document.querySelectorAll("input[type='checkbox']");
checkboxes.forEach((checkbox) => {
if(checkbox.checked) {
checkbox.click();
}
})
Note that your Udemy progress % will not update back to 0%. This is on Udemy's server's end, which I can't control. If you start going through the course again, having a few sections checked off, the percentage should update accordingly.
If this helped you and you want to show your appreciation, consider buying me a coffee ☺ https://ko-fi.com/johndinhdev