prettier-plugin-space-before-function-paren

Prettier plugin to add a space before function parentheses.

MIT 12 个版本
安装
npm install prettier-plugin-space-before-function-paren
yarn add prettier-plugin-space-before-function-paren
pnpm add prettier-plugin-space-before-function-paren
bun add prettier-plugin-space-before-function-paren
README

prettier-plugin-space-before-function-paren

A prettier plugin to add a space before function parentheses for function definitions (but not function calls) in JS and TS. Requires Prettier 3.0.0 or later.

Installation

npm install -D prettier prettier-plugin-space-before-function-paren

Configuration

There are no config options for this plugin. All you need to do is actually include it in your Prettier config:

{
	"plugins": ["prettier-plugin-space-before-function-paren"]
}

[!IMPORTANT] Due to Prettier limitations, to use this plugin with other plugins formatting JS/TS code, install the prettier-plugin-merge plugin and add it to the end of your plugins array. This plugin will be used last and preserve changes made by the previous plugins.

Status

Current version is a proof of concept, please try it out and give feedback!

版本列表
0.1.0 2026-03-14
0.0.10 2025-12-03
0.0.9 2025-10-14
0.0.8 2025-04-24
0.0.7 2025-03-19
0.0.6 2025-03-11
0.0.5 2025-01-21
0.0.4 2025-01-20
0.0.3 2025-01-16
0.0.2 2025-01-15
0.0.1 2025-01-13
0.0.0 2025-01-13