Jens Dahl Møllerhøj


410 Experience
4 Lessons Completed
0 Questions Solved


Hey Chris, have you considered simplifying this by using

JSON.parse('{"color": {"name": "red"}}', object_class: OpenStruct)

It seems to do what you are after :-)

Screencast tutorials to help you learn Ruby on Rails, Javascript, Hotwire, Turbo, Stimulus.js, PostgreSQL, MySQL, Ubuntu, and more.

© 2023 GoRails, LLC. All rights reserved.