Skyline 模式下 mobx-miniprogram-bindings 只能手工绑定吗?BehaviorWithStore绑定报错
import { createStoreBindings } from "mobx-miniprogram-bindings";
import { store as receiveds } from "./reservations";
const STORE_TYPES = {
RECEIVED_RESERVATIONS: "ReceivedReservations",
};
const STORE_CONFIGS = {
[STORE_TYPES.RECEIVED_RESERVATIONS]: {
store: receiveds,
fields: ["receiveds"],
actions: ["updatedReceived"],
},
};
export const handleStores = (context, stores) => {
return stores.map((store) => {
const config = STORE_CONFIGS[store];
if (!config) {
throw new Error(`Unknown store type: ${store}`);
}
return createStoreBindings(context, config);
});
};
需要问一下第三方了