Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Sample code for the Domain-driven design in JavaScript book

NotificationsYou must be signed in to change notification settings

sideshowcoder/ddd-js-sample-code

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Sample code for the Domain-driven design in JavaScript book. The code samplesand additional resources are organized by chapter and example.

Chapter 1

Chapter 2

No sample code in this chapter.

Chapter 3

  • Underscore Source code is availableon Github.
  • PrisonerTransferprisoner transfer module, including the basic layout for the tests, andfeatures runnable.

Chapter 4

  • Weapons: Example how aggregation of weapons could work, calling deep insideobjects, which is most likely a bad idea.node weapons/weapons.js
  • Composition and Inheritance: See the appropriate subfolder.
  • Domain Objects: See chapter 3 prisoner transfer.
  • My Mock: Example mock, built using a simple object, run vianode my_mock/my_mock.js
  • Simple Object: Battle Orcnode simple_objects/battle_orc.js Orcnode simple_objects/orc.js
  • Sinon Example: Example usagesinon for mocking, run vianpm install toinstall dependencies, andnpm test.

Chapter 5

  • ExaggeratingOrcexaggerating_orc.js, shows working with private and publicmethods
  • not a value objectnot_value_objects.js, show how objects can be modified
  • Value object example based on coins,coin.js
  • Using value objects in walletwallet.js
  • Eventsevent.js
  • Orcs repositoryorcs.js
  • Alternative active record style getting orcsorcs_ar.js
  • Sending letter via a postmanpostman.js

Chapter 6

  • sample notifiernpm install to load the dependencies andnpm run notifierto run the code is innotifier.js

Chapter 7

  • sample mathnode math.js
  • using array functions to processnode transport_time.js
  • loggable examplenode oo_orc.js
  • state in basic objects examplenode thing.js
  • eventsnode events.js
  • jumping counter managing statenode counter.js

Chapter 8

  • pjax-example: runnpm install in thechapter_8/pjax-example folder and runnpm start to try it out.
  • ember-example: runnpm install in thechapter_8/ember-example folder and runnpm start to try it out.
  • deactivate_button.html jquery example deativating a button inline, to try itsimply open in a browser.
  • car configuration example to work with constraints and logicnode car_configurator.js

About

Sample code for the Domain-driven design in JavaScript book

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

[8]ページ先頭

©2009-2025 Movatter.jp