Principle Type System Discipline
Marketing & SEO8.3K installs
What it does
Apply when designing types, reviewing a function signature, or writing code in any statically-typed language. Make illegal states unrepresentable, brand semantic primitives, parse external data at boundaries, exhaust variants, derive from authoritative schemas.
Install
npx skills add https://github.com/backnotprop/pstack --skill principle-type-system-disciplineWebsite
www.skills.sh/backnotprop/pstack/principle-type-system-disciplineDetails
From the skill’s SKILL.md or README, by its authors. View the original
Type System Discipline
Make the compiler reject impossible states, mismatched primitives, and unhandled variants. Prefer defining errors and special cases out of existence over proliferating handlers. For TypeScript syntax, see the typescript-best-practices skill.
- Brand semantic primitives.
UserIdandOrderIdare strings underneath but should not be interchangeable. Give each its own type, such as a branded intersection in TypeScript or a newtype elsewhere. Validate once at creation, trust the type downstream. If two arguments share a primitive type but mean different things, brand them. - External data is untyped until parsed. RPC payloads, JSON, IPC messages, CLI args, config files, environment variables, database rows. Have a parse function at every boundary that turns unstructured input into the typed model. The boundary-discipline principle skill says where to put validation.
- Derive types from authoritative schemas. When a protocol buffer, OpenAPI spec, GraphQL schema, database migration, design-token file, or another file owns a shape, derive from it instead of hand-rolling a parallel type. See the encode-lessons-in-structure principle skill.
More Marketing & SEO skills
See allMarketing & SEO
Find Reddit threads where people are genuinely asking for what you offer, then draft short, genuinely helpful replies — disclosing your affiliation honestly and naming your product only when it truly answers the question. Two moves: discovery — scan the right subreddits for…
1.3M installsnpx skills add https://github.com/flowkit-labs/skills --skill reddit-automationMarketing & SEO
When the user wants to audit, review, or diagnose SEO issues on their site. Also use when the user mentions "SEO audit," "technical SEO," "why am I not ranking," "SEO issues," "on-page SEO," "meta tags review," "SEO health check," "my traffic dropped," "lost rankings," "not…
249.6K installsnpx skills add https://github.com/coreyhaines31/marketingskills --skill seo-auditMarketing & SEO
When the user wants to write, rewrite, or improve marketing copy for any page, including homepage, landing pages, pricing pages, feature pages, about pages, or product pages. Also use when the user says "write copy for," "improve this copy," "rewrite this page," "marketing…
249.5K installsnpx skills add https://github.com/coreyhaines31/marketingskills --skill copywritingMarketing & SEO
When the user wants to apply psychological principles, mental models, or behavioral science to marketing. Also use when the user mentions 'psychology,' 'mental models,' 'cognitive bias,' 'persuasion,' 'behavioral science,' 'why people buy,' 'decision-making,' 'consumer…
173.8K installsnpx skills add https://github.com/coreyhaines31/marketingskills --skill marketing-psychology
Skills are shared by members and not reviewed by us. Read a skill’s code before you install it.