Honestly? Just use `attrs` instead of `dataclasses` if you want more control.
It’s like dataclasses but with extra sauce.
```python
import attr
import json
@attr.s
class Item:
id = attr.ib()
name = attr.ib()
data = Item(**json.loads('{"id": 1, "name": "thingy"}'))
```
Now `data.name` works and you get repr/eq for free.
It’s like dataclasses but with extra sauce.
```python
import attr
import json
@attr.s
class Item:
id = attr.ib()
name = attr.ib()
data = Item(**json.loads('{"id": 1, "name": "thingy"}'))
```
Now `data.name` works and you get repr/eq for free.
