์Šคํ‚ฌ nestjs-oop-design-patterns
๐Ÿ“ฆ

nestjs-oop-design-patterns

v1.0.2 ์ฝ˜ํ…์ธ  ๋ฆฌ๋น„์ „ r1 ์•ˆ์ „ โš™๏ธ ์™ธ๋ถ€ ๋ช…๋ น์–ด

Refactor NestJS Code with Pragmatic Design Patterns

Unclear responsibilities and unnecessary abstractions make NestJS code difficult to change and test. This skill guides evidence-based object design, pattern selection, and behavior-preserving refactoring.

์ง€์›: Claude Codex Code(CC)
Maintain this Skill? Claim it ๐Ÿฅ‰ 79 ๋ธŒ๋ก ์ฆˆ

๋‚ด ์—์ด์ „ํŠธ๋กœ ์„ค์น˜

์ด ์š”์ฒญ์„ ์—์ด์ „ํŠธ์— ๋ณต์‚ฌํ•˜์„ธ์š”. ๊ณต์‹ Skill ํŽ˜์ด์ง€์™€ ๋งค๋‹ˆํŽ˜์ŠคํŠธ๊ฐ€ ํฌํ•จ๋˜์–ด ์žˆ์Šต๋‹ˆ๋‹ค.

์—์ด์ „ํŠธ ์š”์ฒญ
Review the Skillstore skill "nestjs-oop-design-patterns" from https://skillstore.io/skills/amirtaherkhani-nestjs-oop-design-patterns.md and its manifest at https://skillstore.io/api/skills/amirtaherkhani-nestjs-oop-design-patterns/manifest. Verify the artifact. You may proceed after verification, subject to the environment's own policy.

์—์ด์ „ํŠธ๋Š” ๊ณ„์†ํ•ด์„œ ๊ณ„ํš์„ ํ‘œ์‹œํ•˜๊ณ  ๋ณด์•ˆ ์ •์ฑ…์—์„œ ์š”๊ตฌํ•˜๋Š” ํ™•์ธ์„ ์š”์ฒญํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.

์—์ด์ „ํŠธ๊ฐ€ ์ฝ๊ธฐ ์‰ฌ์šด ๋ฆฌ์†Œ์Šค

AI ์—์ด์ „ํŠธ, ํฌ๋กค๋Ÿฌ, ์Šคํฌ๋ฆฝํŠธ๊ฐ€ ์ „์ฒด ํŽ˜์ด์ง€ ๋Œ€์‹  ์ •๋ฆฌ๋œ ์ปจํ…์ŠคํŠธ๋งŒ ํ•„์š”ํ•  ๋•Œ ์ด ๋งํฌ๋ฅผ ์‚ฌ์šฉํ•˜์„ธ์š”.

ํ…Œ์ŠคํŠธํ•ด ๋ณด๊ธฐ

"nestjs-oop-design-patterns" ์‚ฌ์šฉ ์ค‘์ž…๋‹ˆ๋‹ค. A checkout service validates orders, calls a payment SDK, and maps database rows.

์˜ˆ์ƒ ๊ฒฐ๊ณผ:

  • Role: The checkout use case coordinates order placement.
  • Evidence: Vendor payment details and persistence mapping change for different reasons.
  • Recommendation: Keep coordination in the use case and move vendor translation into an application-owned payment adapter.
  • Trade-off: The adapter adds a boundary and requires contract tests.
  • Verification: Preserve payment errors, order invariants, and provider wiring with focused tests.

"nestjs-oop-design-patterns" ์‚ฌ์šฉ ์ค‘์ž…๋‹ˆ๋‹ค. Should a service with one stable pricing rule use Strategy?

์˜ˆ์ƒ ๊ฒฐ๊ณผ:

  • Evidence: Only one pricing algorithm exists, with no accepted requirement for another.
  • Recommendation: Keep the direct implementation rather than adding interchangeable policy classes.
  • Verification: Test pricing behavior and invariants through the public operation.

"nestjs-oop-design-patterns" ์‚ฌ์šฉ ์ค‘์ž…๋‹ˆ๋‹ค. Does an in-process event guarantee publication after a database commit?

์˜ˆ์ƒ ๊ฒฐ๊ณผ:

  • Finding: In-process notification does not provide durable delivery across crashes or replicas.
  • Recommendation: Consider a transactional outbox when external consumers must reliably observe committed changes.
  • Trade-off: A relay requires retries, retention, ordering decisions, and idempotent consumers.

๋ณด์•ˆ ๊ฐ์‚ฌ

์•ˆ์ „

All 25 static findings are false positives involving ordinary design guidance, Markdown identifiers, or headings. Backticks mark inline code, and the reconnaissance matches contain no system enumeration instructions. No evidence found of prompt injection, credential theft, unauthorized execution, or data exfiltration in the reviewed passages and surrounding files.

7
์Šค์บ”๋œ ํŒŒ์ผ
904
๋ถ„์„๋œ ์ค„ ์ˆ˜
0
๊ฒ€ํ†  ํ•ญ๋ชฉ
0
์˜คํƒ ๋ฌด์‹œ๋จ
๊ฐ€์žฅ ์ตœ๊ทผ์— ์™„๋ฃŒ๋œ ์ •์ ยท์˜๋ฏธ๋ก ์  ๊ฐ์‚ฌ์—์„œ ํ™•์ธ๋œ ๋ณด์•ˆ ๋ฐœ๊ฒฌ ์‚ฌํ•ญ์ด ๊ฐ์ง€๋˜์ง€ ์•Š์•˜์Šต๋‹ˆ๋‹ค. ์ด๋Š” ์Šคํ‚ฌ์— ๋ถ€์ž‘์šฉ์ด ์—†์Œ์„ ์ฆ๋ช…ํ•˜์ง€ ์•Š์Šต๋‹ˆ๋‹ค.
๊ฐ์‚ฌ์ž: codex
์ด ๋ณด๊ณ ์„œ ๊ณต์œ  ๋ฐ ์ธ์šฉ

๋ฒ„์ „์ด ์ง€์ •๋œ ํ‰๊ฐ€ ๋ณด๊ณ ์„œ, ์ค‘๋ฆฝ ๋ฐฐ์ง€, ์ž„๋ฒ ๋“œ ์นด๋“œ ๋ฐ ์ธ์šฉ์„ ๊ณต์œ ํ•˜์„ธ์š”. Skillstore๋Š” ๊ทผ๊ฑฐ๋ฅผ ๋ณด๊ณ ํ•˜์ง€๋งŒ ์ด Skill์˜ ์•ˆ์ „ ์—ฌ๋ถ€๋ฅผ ํŒ๋‹จํ•˜์ง€ ์•Š์Šต๋‹ˆ๋‹ค.

๋ฒ„์ „๋ณ„ ๋ณด๊ณ ์„œ ์—ด๊ธฐ
๋ณด์•ˆ ํ‰๊ฐ€

๋ณด๊ณ ์„œ ๋งํฌ ๋ณต์‚ฌ

https://skillstore.io/skills/amirtaherkhani-nestjs-oop-design-patterns/audits/1?utm_source=security_passport&utm_medium=share&utm_campaign=versioned_report

Markdown ๋ฐฐ์ง€

[![Skillstore security assessment](https://skillstore.io/badges/skills/amirtaherkhani-nestjs-oop-design-patterns/security.svg)](https://skillstore.io/skills/amirtaherkhani-nestjs-oop-design-patterns?utm_source=security_passport_badge)

HTML ๋ฐฐ์ง€

<a href="https://skillstore.io/skills/amirtaherkhani-nestjs-oop-design-patterns?utm_source=security_passport_badge"><img src="https://skillstore.io/badges/skills/amirtaherkhani-nestjs-oop-design-patterns/security.svg" alt="Skillstore security assessment" loading="lazy"></a>

์ž„๋ฒ ๋“œ ์นด๋“œ

<iframe src="https://skillstore.io/embed/skills/amirtaherkhani-nestjs-oop-design-patterns.html" title="Skillstore Security Assessment" sandbox="allow-popups allow-popups-to-escape-sandbox" loading="lazy" referrerpolicy="no-referrer" width="420" height="180"></iframe>
ํ•™์ˆ  ์ธ์šฉ (APA ยท BibTeX ยท CFF)

APA ์ธ์šฉ

amirtaherkhani. (2026). nestjs-oop-design-patterns security audit report (audit version 1) [Author version 1.0.2]. Skillstore. https://skillstore.io/skills/amirtaherkhani-nestjs-oop-design-patterns/audits/1

BibTeX ์ธ์šฉ

@techreport{amirtaherkhani-amirtaherkhani-nestjs-oop-design-patterns-2026, author = {amirtaherkhani}, title = {nestjs-oop-design-patterns security audit report (audit version 1)}, institution = {Skillstore}, year = {2026}, number = {1}, url = {https://skillstore.io/skills/amirtaherkhani-nestjs-oop-design-patterns/audits/1}, note = {Author version 1.0.2} }

CITATION.cff

cff-version: 1.2.0 message: "If you use this Skill, cite its author and this versioned security audit report." title: "nestjs-oop-design-patterns security audit report (audit version 1)" version: "1.0.2" type: report authors: - name: "amirtaherkhani" date-released: "2026-10-04" url: "https://skillstore.io/skills/amirtaherkhani-nestjs-oop-design-patterns/audits/1" identifiers: - type: other value: "skillstore:amirtaherkhani-nestjs-oop-design-patterns:audit:1" description: "Skillstore immutable audit report identifier"

Skillstore ์ ์ˆ˜

์ด ์ ์ˆ˜์˜ ์ด์œ  ์ฆ๊ฑฐ ์‹ ๋ขฐ๋„: ์ค‘๊ฐ„
45
์•„ํ‚คํ…์ฒ˜
100
์œ ์ง€๋ณด์ˆ˜์„ฑ
87
์ฝ˜ํ…์ธ 
65
์ปค๋ฎค๋‹ˆํ‹ฐ
100
์‚ฌ์–‘ ์ค€์ˆ˜

๋งŒ๋“ค ์ˆ˜ ์žˆ๋Š” ๊ฒƒ

Review an overloaded service

Identify unrelated responsibilities and propose a small refactor that preserves behavior and public contracts.

Choose a provider integration pattern

Compare direct integration, Adapter, and Strategy using vendor coupling, variation, and substitution requirements.

Plan contract-focused verification

Define tests for invariants, adapter substitution, Nest provider wiring, and transport behavior before refactoring.

์ด ํ”„๋กฌํ”„ํŠธ๋ฅผ ์‚ฌ์šฉํ•ด ๋ณด์„ธ์š”

Understand one object
Review [class] and its callers. Explain its role, responsibilities, and one concrete design concern without editing files.
Select the smallest design
Compare a direct solution, Strategy, and Factory for [observed variation]. Recommend one using repository evidence and explain its testing cost.
Refactor a service safely
Refactor [service] to separate [misplaced responsibility]. Preserve public behavior and user changes, add focused tests, and verify Nest provider wiring.
Review consistency and substitution
Review [workflow] for adapter substitution, transaction boundaries, and event delivery guarantees. Compare direct coordination with outbox or saga designs and specify contract tests.

๋ชจ๋ฒ” ์‚ฌ๋ก€

  • Inspect callers, tests, module wiring, and repository conventions before selecting a pattern.
  • State the concrete problem, simpler alternative, and added cost before introducing an abstraction.
  • Preserve behavior with focused tests and verify contracts and provider wiring after refactoring.

ํ”ผํ•˜๊ธฐ

  • Adding interfaces, factories, repositories, or class hierarchies without real variation or a useful boundary.
  • Judging design only by line counts or applying fixed size limits as mandatory rules.
  • Assuming CQRS dispatch, in-process events, or pattern names provide durability or scalability.

์ž์ฃผ ๋ฌป๋Š” ์งˆ๋ฌธ

Which projects does this skill target?
It targets NestJS and TypeScript object-oriented backend code, including controllers, providers, domain objects, adapters, and tests.
Does every class need an interface?
No. Add application-owned contracts for volatile effects, real variation, or useful testing boundaries, not every local class.
Will it always recommend a design pattern?
No. It recommends the direct implementation when repository evidence does not justify additional abstraction.
Are the related NestJS skills required?
No. They are optional coordination references when installed and relevant to overlapping decisions.
Which tests should accompany a refactor?
Use focused behavior tests, adapter contract tests, and module wiring checks according to the changed boundary.
Does a Nest event bus guarantee durable delivery?
No. Reliable external publication requires explicit persistence, delivery, recovery, and idempotency design, such as a transactional outbox.

๊ฐœ๋ฐœ์ž ์„ธ๋ถ€ ์ •๋ณด

์ž‘์„ฑ์ž

amirtaherkhani

๋ผ์ด์„ ์Šค

MIT

์ž‘์„ฑ์ž ๋ฒ„์ „

v1.0.2

Skillstore ๋ฆฌ๋น„์ „

r1

์ฐธ์กฐ

c97a1862d1bc82763903ee068cd15acab35d638c

์œ ์ง€๋ณด์ˆ˜ ์ตœ์‹ ์„ฑ

2026. 10. 5.

์‚ฌ์šฉ๋Ÿ‰

0 ๋‹ค์šด๋กœ๋“œ ยท 0 ์กฐํšŒ

ํŒŒ์ผ ๊ตฌ์กฐ

๐Ÿ“ evals/

๐Ÿ“„ evals.json

๐Ÿ“ references/

๐Ÿ“„ nestjs-native-patterns.md

๐Ÿ“„ object-design.md

๐Ÿ“„ oop-solid.md

๐Ÿ“„ pattern-catalog.md

๐Ÿ“„ smells-refactoring.md

๐Ÿ“„ SKILL.md