JSFiddle - React, Tailwind, and code Playground
by insin
HTML
<script src="https://raw.github.com/insin/concur/master/concur.js"></script>
<div id='cont' style="border:1px solid blue">test</div>
JavaScript
var A = Concur.extend({
view: function() {
this.$ele = $('<select><option>o1</option><option>o2</option></select>')
this.$ele.bind('change', this.on_change)
$('#cont').html(this.$ele)
}
, on_change: function() {
alert('changed')
}
, test: function() {
alert('a')
}
})
/*
var a = new A();
a.view();
*/
/* ***************** derived ************* */
var B = A.extend({
test: function() {
alert('b')
}
})
var b = new B()
b.view()
b.test()