mirror of
https://github.com/flarum/framework.git
synced 2025-05-22 14:49:57 +08:00
Initialise component state in init() instead of constructor
This allows component state to be overridden via monkey-patch. ref #246
This commit is contained in:
@ -14,9 +14,7 @@ import icon from 'flarum/helpers/icon';
|
||||
* - `children` A text label to display next to the checkbox.
|
||||
*/
|
||||
export default class Checkbox extends Component {
|
||||
constructor(...args) {
|
||||
super(...args);
|
||||
|
||||
init() {
|
||||
/**
|
||||
* Whether or not the checkbox's value is in the process of being saved.
|
||||
*
|
||||
|
Reference in New Issue
Block a user