Fork me on GitHub
#reagent
<
2016-05-30
>
luposlip10:05:40

Actually js/Ons just return an empty object: Object {}

deddu23:05:24

hey fellas, anyone has a successful story of integrating react-mdl with reagent?

deddu23:05:40

just’ can’t figure out what the element is

deddu23:05:17

can someone point me to one working example ?

deddu23:05:55

I’ve read the source but still it makes no sense * @param {HTMLElement} element The element that will be upgraded.

deddu23:05:05

what element you put inside a checkbox??

deddu23:05:21

/**
   * Class constructor for Checkbox MDL component.
   * Implements MDL component design pattern defined at:
   * 
   *
   * @constructor
   * @param {HTMLElement} element The element that will be upgraded.
   */
var MaterialCheckbox = function MaterialCheckbox(element) {
    this.element_ = element;
    // Initialize instance.
    this.init();
};

deddu23:05:12

I mean, I can pass it a component as a first argument, but that fucntion is looking for this

deddu23:05:53

and I can clearly pass it this trough js/MaterialCheckbox.call but it obviously doesn’t have init