├── .idea ├── .gitignore ├── js_design_principles.iml ├── modules.xml └── vcs.xml ├── README.md ├── __tests__ ├── dependency_inversion │ ├── html_serializer.test.js │ ├── response_writer.test.js │ ├── string_serializer.test.js │ └── xml_serializer.test.js ├── interface_segregation │ ├── book.test.js │ ├── book_stats.test.js │ └── library.test.js ├── liskov_substitution │ └── bank_account.test.js ├── open_closed │ └── video_library.test.js ├── single_responsibility │ └── bank_transfer.test.js └── tell_dont_ask │ └── carpet_quote.test.js ├── jest.config.js ├── package.json └── src ├── dependency_inversion ├── html_serializer.js ├── response_writer.js ├── string_serializer.js └── xml_serializer.js ├── interface_segregation ├── book.js ├── book_stats.js └── library.js ├── liskov_substitution └── bank_account.js ├── open_closed └── video_library.js ├── single_responsibility ├── bank_account.js └── bank_transfer.js └── tell_dont_ask └── carpet_quote.js /.idea/.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/.idea/.gitignore -------------------------------------------------------------------------------- /.idea/js_design_principles.iml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/.idea/js_design_principles.iml -------------------------------------------------------------------------------- /.idea/modules.xml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/.idea/modules.xml -------------------------------------------------------------------------------- /.idea/vcs.xml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/.idea/vcs.xml -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/README.md -------------------------------------------------------------------------------- /__tests__/dependency_inversion/html_serializer.test.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/__tests__/dependency_inversion/html_serializer.test.js -------------------------------------------------------------------------------- /__tests__/dependency_inversion/response_writer.test.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/__tests__/dependency_inversion/response_writer.test.js -------------------------------------------------------------------------------- /__tests__/dependency_inversion/string_serializer.test.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/__tests__/dependency_inversion/string_serializer.test.js -------------------------------------------------------------------------------- /__tests__/dependency_inversion/xml_serializer.test.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/__tests__/dependency_inversion/xml_serializer.test.js -------------------------------------------------------------------------------- /__tests__/interface_segregation/book.test.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/__tests__/interface_segregation/book.test.js -------------------------------------------------------------------------------- /__tests__/interface_segregation/book_stats.test.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/__tests__/interface_segregation/book_stats.test.js -------------------------------------------------------------------------------- /__tests__/interface_segregation/library.test.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/__tests__/interface_segregation/library.test.js -------------------------------------------------------------------------------- /__tests__/liskov_substitution/bank_account.test.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/__tests__/liskov_substitution/bank_account.test.js -------------------------------------------------------------------------------- /__tests__/open_closed/video_library.test.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/__tests__/open_closed/video_library.test.js -------------------------------------------------------------------------------- /__tests__/single_responsibility/bank_transfer.test.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/__tests__/single_responsibility/bank_transfer.test.js -------------------------------------------------------------------------------- /__tests__/tell_dont_ask/carpet_quote.test.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/__tests__/tell_dont_ask/carpet_quote.test.js -------------------------------------------------------------------------------- /jest.config.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/jest.config.js -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/package.json -------------------------------------------------------------------------------- /src/dependency_inversion/html_serializer.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/src/dependency_inversion/html_serializer.js -------------------------------------------------------------------------------- /src/dependency_inversion/response_writer.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/src/dependency_inversion/response_writer.js -------------------------------------------------------------------------------- /src/dependency_inversion/string_serializer.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/src/dependency_inversion/string_serializer.js -------------------------------------------------------------------------------- /src/dependency_inversion/xml_serializer.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/src/dependency_inversion/xml_serializer.js -------------------------------------------------------------------------------- /src/interface_segregation/book.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/src/interface_segregation/book.js -------------------------------------------------------------------------------- /src/interface_segregation/book_stats.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/src/interface_segregation/book_stats.js -------------------------------------------------------------------------------- /src/interface_segregation/library.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/src/interface_segregation/library.js -------------------------------------------------------------------------------- /src/liskov_substitution/bank_account.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/src/liskov_substitution/bank_account.js -------------------------------------------------------------------------------- /src/open_closed/video_library.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/src/open_closed/video_library.js -------------------------------------------------------------------------------- /src/single_responsibility/bank_account.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/src/single_responsibility/bank_account.js -------------------------------------------------------------------------------- /src/single_responsibility/bank_transfer.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/src/single_responsibility/bank_transfer.js -------------------------------------------------------------------------------- /src/tell_dont_ask/carpet_quote.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jasongorman/JS_design_principles/HEAD/src/tell_dont_ask/carpet_quote.js --------------------------------------------------------------------------------