binaryage / binaryage/cljs-oops
oset being strict
- Lingua principale
- Clojure
- Stelle
- 350
- Fork
- 13
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Descrizione
Hello,
I'm trying to use oops to interop with [Automerge](https://github.com/automerge/automerge).
This snippet fails to make an update:
```clojure
(oset+ doc "todos" (str idx) "done" true)
```
The browser complaints that: `data property descriptor has writable=false`
But if I try something a bit different:
```clojure
(gobj/set (oget+ doc "todos" (str idx)) "done" done)
```
This works just fine, the google impl is a single `obj[key] = value`. I wonder if there is a way to make `oops` work directly without having to fall back into Closure helpers.
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
Direzione di ricerca
Start with the oset+ entry point and compare its behavior with the working gobj/set call on the same doc, todos, index, and done values. Trace how oset+ performs the nested update and verify the fix against the reported Automerge case, ensuring direct oops access no longer produces the writable=false browser error.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- clojure, javascript
- Ambito
- tooling
- Tipo di issue
- Bug
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Stato di attività
- Ferma
- Chiarezza
- Abbastanza chiara
- Idoneità per principianti
- 35/100