jamiemthomas / jquery-datalink

A data linking plugin for jQuery.
http://jamiemthomas.github.com/jquery-datalink
5 stars 2 forks source link

null and undefined values showing up as "null" and "undefined" #3

Open DrZim opened 14 years ago

DrZim commented 14 years ago

Plug-in is working great. The "null" and "undefined" rendered values are back.

jamiemthomas commented 14 years ago

I will add test cases for null and undefined values to make sure I catch this in the future. I refactored the convert logic and ultimately messed up my handling of null coercion. Essentially, if a converter returns undefined, binding is not supposed to occur at all, if it returns null, this should be converted to "" instead of the javascript default of "null", so each of these need to be correctly special cased. I will let you know when a fix is checked in, or you can watch the repository if you prefer.

Again, thanks for the feedback. I wish there was more progress on the main branch!

DrZim commented 14 years ago

Thank you for writing such fine software. It has a two part benefit for us, namely the software itself, and reading through the JS to see how well it is put together. Nicely done.