(target, prop, value)
| 12 | export function createStore(name, initialState) { |
| 13 | const proxy = new Proxy(initialState, { |
| 14 | set(target, prop, value) { |
| 15 | const store = globalThis.Alpine?.store(name); |
| 16 | if (store) store[prop] = value; |
| 17 | else target[prop] = value; |
| 18 | return true; |
| 19 | }, |
| 20 | get(target, prop) { |
| 21 | const store = globalThis.Alpine?.store(name); |
| 22 | if (store) return store[prop]; |
no outgoing calls