[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill-799d566d-4f61-4e00-915d-1a7b180783c5":3,"$fOC8x5CgNTNcvccogH0KmiBFmBspiBX-9W0Q81ocK83I":42},{"id":4,"title":5,"description":6,"categoryId":7,"moduleId":8,"tags":9,"prompt":10,"icon":11,"source":12,"sourceUrl":13,"authorId":14,"authorName":15,"isPublic":16,"stars":17,"runs":18,"createdAt":19,"updatedAt":19,"module":20,"category":27,"packages":33},"799d566d-4f61-4e00-915d-1a7b180783c5","fp-types-ref","fp-ts类型快速参考。当用户询问使用哪种类型、需要Option\u002FEither\u002FTask决策帮助或想要fp-ts导入时使用。","cat_prod_project","mod_productivity","sickn33,productivity","---\nname: fp-types-ref\ndescription: Quick reference for fp-ts types. Use when user asks which type to use, needs Option\u002FEither\u002FTask decision help, or wants fp-ts imports.\nrisk: safe\nsource: community\nversion: 1.0.0\ntags: [fp-ts, typescript, quick-reference, option, either, task]\n---\n\n# fp-ts Quick Reference\n\n## When to Use\n- You need help choosing between `Option`, `Either`, `Task`, `TaskEither`, or related fp-ts types.\n- The task is about imports, decision guidance, or selecting the right abstraction for a TypeScript flow.\n- You want a compact reference for common fp-ts type choices and patterns.\n\n## Which Type Should I Use?\n\n```\nIs the operation async?\n├─ NO: Does it involve errors?\n│   ├─ YES → Either\u003CError, Value>\n│   └─ NO: Might value be missing?\n│       ├─ YES → Option\u003CValue>\n│       └─ NO → Just use the value\n└─ YES: Does it involve errors?\n    ├─ YES → TaskEither\u003CError, Value>\n    └─ NO: Might value be missing?\n        ├─ YES → TaskOption\u003CValue>\n        └─ NO → Task\u003CValue>\n```\n\n## Common Imports\n\n```typescript\n\u002F\u002F Core\nimport { pipe, flow } from 'fp-ts\u002Ffunction'\n\n\u002F\u002F Types\nimport * as O from 'fp-ts\u002FOption'      \u002F\u002F Maybe exists\nimport * as E from 'fp-ts\u002FEither'      \u002F\u002F Success or failure\nimport * as TE from 'fp-ts\u002FTaskEither' \u002F\u002F Async + failure\nimport * as T from 'fp-ts\u002FTask'        \u002F\u002F Async (no failure)\nimport * as A from 'fp-ts\u002FArray'       \u002F\u002F Array utilities\n```\n\n## One-Line Patterns\n\n| Need | Code |\n|------|------|\n| Wrap nullable | `O.fromNullable(value)` |\n| Default value | `O.getOrElse(() => default)` |\n| Transform if exists | `O.map(fn)` |\n| Chain optionals | `O.flatMap(fn)` |\n| Wrap try\u002Fcatch | `E.tryCatch(() => risky(), toError)` |\n| Wrap async | `TE.tryCatch(() => fetch(url), toError)` |\n| Run pipe | `pipe(value, fn1, fn2, fn3)` |\n\n## Pattern Match\n\n```typescript\n\u002F\u002F Option\npipe(maybe, O.match(\n  () => 'nothing',\n  (val) => `got ${val}`\n))\n\n\u002F\u002F Either\npipe(result, E.match(\n  (err) => `error: ${err}`,\n  (val) => `success: ${val}`\n))\n```\n\n## Limitations\n- Use this skill only when the task clearly matches the scope described above.\n- Do not treat the output as a substitute for environment-specific validation, testing, or expert review.\n- Stop and ask for clarification if required inputs, permissions, safety boundaries, or success criteria are missing.\n","","imported","https:\u002F\u002Fgithub.com\u002Fsickn33\u002Fantigravity-awesome-skills","user_system_seed","SkillOPIC",true,78,1125,"2026-05-16 13:19:03",{"id":8,"name":21,"slug":22,"icon":23,"description":24,"sort":25,"createdAt":26},"效率工具","productivity","mdi-lightning-bolt-outline","文档处理、数据分析、自动化工作流",4,"2026-05-16 12:53:40",{"id":7,"name":28,"slug":29,"icon":30,"description":31,"moduleId":8,"sort":25,"skillCount":32,"createdAt":26},"项目管理","project-management","mdi-view-dashboard-outline","任务管理、进度追踪、报告生成",13,[34],{"id":35,"skillId":4,"version":36,"fileName":37,"fileSize":38,"filePath":39,"fileHash":40,"manifest":41,"createdAt":19},"f125e993-f15d-49a7-b4b9-5078267beb1d","1.0.0","fp-types-ref.zip",1215,"uploads\u002Fskills\u002F799d566d-4f61-4e00-915d-1a7b180783c5\u002Ffp-types-ref.zip","23342ce9d20c62e2bce46d26835b7f2ba842a2dbb791479cf6107801a4f26552","[{\"path\":\"SKILL.md\",\"isDirectory\":false,\"size\":2364}]",{"code":43,"message":44,"data":45},200,"success",{"items":46,"stats":47,"page":50},[],{"averageRating":48,"totalRatings":48,"ratingCounts":49},0,[48,48,48,48,48],{"limit":51,"offset":48,"hasMore":52,"nextOffset":51,"ratedOnly":16},15,false]