code_formatter
БесплатноБез исполняемых скриптовНе проверенOtomatik kod formatlama, Prettier/ESLint entegrasyonu ve kod stil tutarlılığı rehberi.
Об этом скилле
🎨 Code Formatter
Otomatik kod formatlama ve stil tutarlılığı rehberi.
📋 Prettier Yapılandırması
.prettierrc
{
"semi": true,
"singleQuote": true,
"tabWidth": 2,
"trailingComma": "es5",
"printWidth": 80,
"bracketSpacing": true,
"arrowParens": "avoid",
"endOfLine": "lf"
}
Komutlar
# Format single file
npx prettier --write src/file.ts
# Format all files
npx prettier --write "src/**/*.{ts,tsx,js,jsx,json,css,md}"
# Check without writing
npx prettier --check "src/**/*"
🔧 ESLint Entegrasyonu
.eslintrc.js
module.exports = {
extends: [
'eslint:recommended',
'plugin:@typescript-eslint/recommended',
'plugin:react/recommended',
'prettier', // Prettier çakışmalarını devre dışı bırakır
],
plugins: ['@typescript-eslint', 'react'],
rules: {
'no-console': 'warn',
'no-unused-vars': 'error',
},
};
Komutlar
# Lint
npx eslint src/
# Lint and fix
npx eslint src/ --fix
# Specific files
npx eslint "src/**/*.{ts,tsx}"
🔄 Git Hooks (Husky + lint-staged)
package.json
{
"lint-staged": {
"*.{ts,tsx,js,jsx}": [
"eslint --fix",
"prettier --write"
],
"*.{json,css,md}": [
"prettier --write"
]
}
}
Setup
npx husky-init && npm install
npx husky add .husky/pre-commit "npx lint-staged"
📁 Ignore Files
.prettierignore
node_modules/
dist/
build/
.next/
coverage/
*.min.js
.eslintignore
node_modules/
dist/
build/
*.config.js
Code Formatter v1.1 - Enhanced
🔄 Workflow
Kaynak: Prettier Docs
Aşama 1: Installation
- Packages:
prettier,eslintve ilgili pluginleri kur. - Config:
.prettierrcve.eslintrcdosyalarını kök dizine ekle. - Ignore:
.prettierignoredosyasınabuild/,dist/ekle.
Aşama 2: Automation
- Scripts:
package.jsoniçineformatvelintscriptlerini ekle. - VS Code:
.vscode/settings.jsonile "Format on Save" aç. - Hooks: Husky ve lint-staged ile commit öncesi kontrol ekle.
Aşama 3: CI Integration
- Pipeline: CI sürecine
npm run lintveprettier --checkadımlarını ekle.
Kontrol Noktaları
| Aşama | Doğrulama |
|---|---|
| 1 | npm run format çalışınca dosyalar değişiyor mu? |
| 2 | Hatalı bir kod commit edilmeye çalışıldığında Husky engelliyor mu? |
| 3 | CI pipeline format hatası olduğunda fail ediyor mu? |
Установить code_formatter в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл code_formatter?
Otomatik kod formatlama, Prettier/ESLint entegrasyonu ve kod stil tutarlılığı rehberi.
Как установить скилл code_formatter?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл code_formatter запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
theme-factory
Toolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with…
от Anthropicaccess
Manage Discord channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropicconfigure
Set up the Discord channel — save the bot token and review access policy. Use when the user pastes a Discord bot token, asks to configure Discord, asks "how…
от Anthropicaccess
Manage iMessage channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropic