{"success":true,"name":"search-for-an-existing-solution-before-building-your-own","description":"About to write from scratch something that sounds like a common need","category":"ai-brimind","path":"ai-brimind/search-for-an-existing-solution-before-building-your-own/SKILL.md","file":"SKILL.md","content":"---\nname: search-for-an-existing-solution-before-building-your-own\ndescription: \"About to write from scratch something that sounds like a common need\"\n---\n\n# Search for an Existing Solution Before Building Your Own\n\n## When to use\nYou are about to hand-build something with an industry name (date handling, validation, pagination, auth, file upload) without checking what already exists.\n\n## Example request\nHand-writing date math → timezones and leap years eat you alive; a battle-tested library existed. Building custom password auth → security holes guaranteed; that is a solved problem you shouldn't re-solve. Writing your own CSV parser → quotes and commas inside fields break it; edge cases are why libraries exist. Rebuilding a helper that already exists in the project → two versions drift; search the codebase first.\n\n## Instructions\nAdopt the mindset of a chef who checks the pantry before driving to the store, and checks the store before farming. Before building: (1) Name what you need in industry terms — if it has a common name ('debounce', 'pagination', 'schema validation'), thousands solved it before you. (2) Search in order: does THIS project already have it (a helper, an existing pattern)? Does the language or framework have it built in? Does a well-maintained, popular library cover it? (3) Evaluate candidates like an adult: maintained, widely used, covers your actual case — not just the first result. (4) Custom code is the LAST resort and must be justified: 'nothing fits because X.' Even then, write thin glue around existing pieces rather than a full reinvention. If unsure whether something qualifies as 'solved', ask or spend ten minutes searching — cheaper than a week of building. Only build custom once reuse is confirmed impossible or unfit, and state what you searched and why it didn't fit.\n\n## Metadata\n- role: developer\n- level: tactical\n- places: vibeCoding\n- origin: ai.brimind.pro skill #272\n","linked_files":[],"origin":"ai.brimind.pro","owner_id":null,"source":"router"}