Files
cats.service.ts
What you'll learn
- Declare fields, a constructor and methods, and use parameter properties to receive and keep a dependency
- Hide state with private and protect it with readonly, and share a constant with static
- Implement an interface, and depend on the interface so any object with its shape can be passed in
Press Run tests to start the app. Its log appears here.Tests
- cats.service.spec.tsrun to see its tests