lambdaisland

plexus 2016-12-17T10:36:20.000175Z

@dhruv1 no experience with this, but what you're doing there with aget looks fishy

plexus 2016-12-17T10:37:09.000176Z

pulling a function out like that will lose track of this, which might be your problem. It's also a recipe for getting troubles with advanced compilation

plexus 2016-12-17T10:39:57.000177Z

no, scratch that. RadioButton is an ES6 class. Still better to do a (.-RadioButton js/MaterialUI), but that probably won't solve your problem

martinklepsch 2016-12-17T15:12:03.000181Z

@dhruv1 It seems the MaterialUI stuff expects some React Context to be present to define the theme

martinklepsch 2016-12-17T15:13:46.000182Z

If you look at the source for RadioButton you probably see something like contextTypes {muiTheme String} (pseudocode because I don't know JS lol)

martinklepsch 2016-12-17T15:16:12.000183Z

What you'll need to do is set this context at the root of your component tree and then also create components that have contextTypes as above. I haven't done this with Reagent but I'd say it's a bit more advanced so depending on your experience you may want to choose this battle wisely 🙂

martinklepsch 2016-12-17T15:16:30.000184Z

There's a bit more context around all this in this README https://github.com/madvas/cljs-react-material-ui

martinklepsch 2016-12-17T15:16:47.000186Z

Take particular note about the mui-theme-provider

martinklepsch 2016-12-17T15:17:18.000187Z

Also there are some Reagent usage notes 🙂