the book is based on principles of Clojure prog. language,
that has unique and advance way of handling data
and apparently TypeScript also supports concepts of "Data Oriented" programming
- Separate code from data
- Represent data with generic data structures
- Manipulate data with general-purpose functions
- Manage state without mutating data
- Control concurrency in highly scalable systems
- Write data-oriented unit tests
- Specify the shape of your data
- Benefit from polymorphism without objects
- Debug programs without a debugger
podcast interview with the book author;
The principles of data-oriented programming with Yehonathan Sharvit (The Changelog #522) |> Changelog
In DOP, data is treated as a first-class citizen.
The essence of DOP is that it treats data as a first-class citizen. It gives developers the ability to manipulate data inside a program with the same simplicity as they manipulate numbers or strings. Treating data as a first-class citizen is made possible by adhering to four core principles:
Principle #1: Separating code (behavior) from data.
Principle #2: Representing data with generic data structures.
Principle #3: Treating data as immutable.
Principle #4: Separating data schema from data representation.
viebel (Yehonathan Sharvit) @GitHub
Post a Comment