首页
Tom Utilities

JavaScript 格式化

HTML、CSS 与 JavaScript

使用恰当的缩进、空格和换行美化 JavaScript。

输入

结果

使用方法

How to format JavaScript

Paste JavaScript and press Format. Statements and blocks are placed on readable lines.

  1. Paste JavaScript into the input editor.
  2. Press Format.
  3. Copy the beautified code.

常见问题

Will my code still run?

Yes, formatting only changes whitespace and line breaks, never logic.

Is my code sent anywhere?

No, formatting happens in your browser and the code is never uploaded.