Book Image

JavaScript Domain-Driven Design

Book Image

JavaScript Domain-Driven Design

Overview of this book

Table of Contents (15 chapters)
JavaScript Domain-Driven Design
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Domain-specific languages


Using specific keywords to describe parts of the domain is one of the main goals we set out to achieve in building a system using domain-driven design. Especially the LISP community, which has been an influence on JavaScript (http://readwrite.com/2011/07/22/javascript-was-no-accident), there is a strong tendency to meld the language to the problem. This naturally leads to further trying to make the language fit the domain, with the ultimate goal of having a language that is perfect for solving the specific problem the domain has.

This kind of development is referred to as using Domain-specific Languages, or DSL for short. In day-to-day work, there are lots of very DSLs we come across, be it CSS to describe the style of a HTML document, or SQL for interfacing with the database. The lines when a language is a DSL and when it is a general-purpose language are often a bit blurred. SQL, for example, is often considered a "real" programming language, so to speak, even...