Leetcode auto delete local submissions

Useful when you try to solve a problem again if you don't want to see your past submission. This script removes the cache and set the leetcode language to python3 (feel free to change it).

  1. // ==UserScript==
  2. // @name Leetcode auto delete local submissions
  3. // @version 2023-12-10
  4. // @description Useful when you try to solve a problem again if you don't want to see your past submission. This script removes the cache and set the leetcode language to python3 (feel free to change it).
  5. // @author You
  6. // @match https://leetcode.com/*
  7. // @icon https://www.google.com/s2/favicons?sz=64&domain=leetcode.com
  8. // @grant none
  9. // @license MIT
  10. // @namespace https://greasyfork.org/users/1235671
  11. // ==/UserScript==
  12.  
  13. (function() {
  14. 'use strict';
  15. localStorage.clear();
  16. localStorage.setItem("global_lang","python3");
  17. localStorage.setItem("QD_SHOWN_DYNAMIC_LAYOUT_MODAL","true");
  18. })();