js: upgrade to MobX 6.0.
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import { h, Component, render } from "preact";
|
||||
import { observable, computed, action } from "mobx";
|
||||
import { makeObservable, observable, computed, action } from "mobx";
|
||||
import { observer } from "mobx-react";
|
||||
|
||||
import Utility from "./utility";
|
||||
@@ -10,6 +10,11 @@ export default @observer class TagCounter extends Component {
|
||||
|
||||
@observable tagCount = 0;
|
||||
|
||||
constructor() {
|
||||
super();
|
||||
makeObservable(this);
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
$(this.props.tags).on("input", this.updateCount);
|
||||
this.updateCount();
|
||||
|
||||
Reference in New Issue
Block a user