Cosmiconfig Setup
SkillDev toolsSet up cosmiconfig for hierarchical configuration loading from multiple sources and formats.
Use Cosmiconfig Setup in Claude, ChatGPT or Ahel Desktop
Free. Sign in, add Cosmiconfig Setup and connect your AI. About a minute.
Also: Claude Code · Cursor · Codex
Then ask your AI: use the Cosmiconfig Setup skill
Details
Instructions available. Your AI can read the instructions. Execution depends on the setup they require.
Account requirements not reviewed. Check the skill instructions before use; Ahel provides instructions and does not run this skill.
No other account needed.
Add Ahel to your AI once: Claude, ChatGPT, Cursor, Claude Code or Codex. Then ask it to use this.
What this skill tells your AI
The instructions your AI receives, as published by a5c-ai/babysitter in library/specializations/cli-mcp-development/skills/cosmiconfig-setup/SKILL.md and read by Ahel’s review.
Set up cosmiconfig for hierarchical config loading.
Capabilities
- Configure cosmiconfig search paths
- Set up format loaders (JSON, YAML, TOML)
- Create TypeScript config support
- Implement config caching
- Handle config validation
Generated Patterns
import { cosmiconfig, cosmiconfigSync } from 'cosmiconfig';
import { TypeScriptLoader } from 'cosmiconfig-typescript-loader';
const moduleName = 'myapp';
const explorer = cosmiconfig(moduleName, {
searchPlaces: [
'package.json',
`.${moduleName}rc`,
`.${moduleName}rc.json`,
`.${moduleName}rc.yaml`,
`.${moduleName}rc.yml`,
`.${moduleName}rc.js`,
`.${moduleName}rc.ts`,
`.${moduleName}rc.cjs`,
`${moduleName}.config.js`,
`${moduleName}.config.ts`,
`${moduleName}.config.cjs`,
],
loaders: {
'.ts': TypeScriptLoader(),
},
});
export async function loadConfig(searchFrom?: string) {
const result = await explorer.search(searchFrom);
if (!result || result.isEmpty) {
return { config: getDefaultConfig(), filepath: null };
}
return { config: { ...getDefaultConfig(), ...result.config }, filepath: result.filepath };
}
Target Processes
- configuration-management-system
- cli-application-bootstrap
- mcp-server-bootstrap
Signals
- GitHub stars
- 2k
- Forks
- 113
- Last commit
- Sep 2026
Advanced
- Item type
- skill
- Key
cosmiconfig-setup- Source
- github.com/a5c-ai/babysitter
Related picks
Skill · thedaviddias
The pick for JavaScriptmodern-javascript-patterns
Skill · wshobson
The pick for JavaScriptsetup-ts-deep-modules
Skill · mattpocock
The pick for TypeScripttypescript-pro
Skill · jeffallan
The pick for TypeScriptnodejs-backend-patterns
Skill · wshobson
The pick for Noderun-node-tests
Skill · hiroro-work
The pick for Node