bruth / synapse

Hooks to support data binding between virtually any object.
http://bruth.github.com/synapse/docs/
BSD 2-Clause "Simplified" License
150 stars 6 forks source link

examples #10

Closed pgherveou closed 12 years ago

pgherveou commented 12 years ago

Hello I tried some of the examples in my code today Shouldn't the handler attribute in the example page be named converter according to your doc ?


Synapse('span').observe('input', {
    subjectInterface: 'value',
    observerInterface: 'html',
    handler: function(value) {
        if (value !== '')
            return 'I am a <b>' + value + '</b>';
        return '<em class="meta">please type something</em>';
    }
});