Leetcode format

Adds Format code button on leetcode to format the code using Prettier code formatter

Leetcode Format - A Code Formatting Extension for Prettier Code

'Leetcode format' is a Chrome extension that enables users to easily format their code in Leetcode's code editor using the Prettier code formatter. This versatile tool supports both Java, C++, JavaScript, TypeScript and Dart languages and equally functions on LeetCode's old and new UI including the dynamic layout. With its hotkey support, users can quickly format their code to ensure improved readability and cleaner presentation. It continually updates to ensure compatibility with Leetcode's UI changes and to fix-any-existing bugs.
Install from Chrome Web Store

Extension stats

Users: 5,000+
Rating: 4.30
(30)
Version: 1.9 (Last updated: 2023-12-25)
Creation date: 2020-12-27
Risk impact: Low risk impact
Risk likelihood:
Manifest version: 3
Size: 2.54M

Other platforms

Leetcode Python (v1.28)
4.44 (278) 86,135+
LeetCode format (v1.0)
1.00 (1) 47
Not available on Edge
Want to check extension ranking and stats more quickly for other Chrome extensions? Install Chrome-Stats extension to view Chrome-Stats data as you browse the Chrome Web Store.

Extension summary

This Google chrome extension adds the Format button to the LeetCode code editor. Currently supported programming languages are Java, C++, JavaScript, TypeScript and Dart.

Supports LeetCode old and new UI both, including dynamic layout.

Release Notes 1.9:

  • Bug fix with dynamic layout

Release Notes 1.8:

  • Bug fixes

Release Notes 1.7:

  • Bug fixes for new UI
  • Add hotkey support for old UI as well

Release Notes v1.6:

See more

User reviews

These summaries are automatically generated weekly using AI based on recent user reviews. Chrome Web Store does not verify user reviews, so some user reviews may be inaccurate, spammy, or outdated.
Pros
  • Works perfectly for many users, especially with C++.
  • Open source extension which allows for community contributions.
  • Has been described as a lifesaver for LeetCode users.
  • Offers formatting functionality that enhances code readability.
Cons
  • Not working on the new Dynamic Layout of LeetCode.
  • Formatting issues with certain syntax (e.g., min and max not aligning as desired).
  • Does not support Java effectively according to some users.
  • Line numbering gets disturbed after installation.
Most mentioned
  • Does not work on Dynamic Layout.
  • Works perfectly for some languages like C++.
  • Feature request for keyboard shortcut.
  • Formatting button missing in the new UI or leetcode.cn.
User reviews
by Ismael Boussatta, 2024-06-22

Great Extension , but can you change the formatting of min and max , because if written in the form of min({a,b,c}) , it puts a , b , c in different lines which looks really weird . Thanks!
by Harsh Narayan, 2024-01-19

The key bindings are not working on Mac
by Aman malik, 2024-01-16
View all user reviews

Extension safety

Risk impact

Leetcode format requires very minimum permissions.

Risk likelihood

Leetcode format has earned a good reputation and can be trusted.

Upgrade to see risk analysis details

Similar extensions

Here are some Chrome extensions that are similar to Leetcode format: