Decorators Intro
Decorators (Stage 3) ช่วยเพิ่ม metadata และ modify behaviors ของ classes, methods, และ properties โดยไม่ต้องแก้ไข code ตรงๆ
ประเภท Decorators
Section titled “ประเภท Decorators”| ประเภท | ใช้กับ | ตัวอย่าง |
|---|---|---|
| Class | Class declaration | @sealed |
| Method | Class methods | @log |
| Property | Class properties | @readonly |
| Accessor | Getters/Setters | @computed |
| Parameter | Method params | @inject |
Decorator Flow
Section titled “Decorator Flow”เข้าสู่ระบบเพื่อดูเนื้อหาเต็ม
ยืนยันตัวตนด้วยบัญชี Google เพื่อปลดล็อกบทความทั้งหมด
Login with Google