1# JavaScript
2
3- Tree Sitter: [tree-sitter-javascript](https://github.com/tree-sitter/tree-sitter-javascript)
4- Language Server: [typescript-language-server](https://github.com/typescript-language-server/typescript-language-server)
5
6### Code formatting
7
8Formatting on save is enabled by default for JavaScript, using TypeScript's built-in code formatting. But many JavaScript projects use other command-line code-formatting tools, such as [Prettier](https://prettier.io/). You can use one of these tools by specifying an _external_ code formatter for JavaScript in your settings. See the [configuration](../configuration/configuring-zed.md) documentation for more information.
9
10For example, if you have Prettier installed and on your `PATH`, you can use it to format JavaScript files by adding the following to your `settings.json`:
11
12```json
13{
14 "language_overrides": {
15 "JavaScript": {
16 "format_on_save": {
17 "external": {
18 "command": "prettier",
19 "arguments": ["--stdin-filepath", "{buffer_path}"]
20 }
21 }
22 }
23 }
24}
25```