Suggestion for a new code example. PR637
This commit is contained in:
parent
7cc8a1e699
commit
7ad1b01463
@ -502,20 +502,21 @@ interface SelectableControl extends Control {
|
||||
select(): void;
|
||||
}
|
||||
|
||||
class Button extends Control {
|
||||
class Button extends Control implements SelectableControl {
|
||||
select() { }
|
||||
}
|
||||
|
||||
class TextBox extends Control {
|
||||
select() { }
|
||||
|
||||
}
|
||||
|
||||
class Image {
|
||||
// Error: Property 'state' is missing in type 'Image'.
|
||||
class Image implements SelectableControl {
|
||||
select() { }
|
||||
}
|
||||
|
||||
class Location {
|
||||
select() { }
|
||||
|
||||
}
|
||||
```
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user