Re: [openstack-dev] [horizon] function expressions vs function declarations in JavaScript

2015-01-15 Thread Aaron Sahlin
) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org From: Matthew Farina m...@mattfarina.com mailto:m...@mattfarina.com Date: 01/14/2015 07:04AM Subject: [openstack-dev] [horizon] function expressions vs function declarations in JavaScript

Re: [openstack-dev] [horizon] function expressions vs function declarations in JavaScript

2015-01-14 Thread Matthew Farina
too much. -Matthew Farina m...@mattfarina.com wrote: - To: OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org From: Matthew Farina m...@mattfarina.com Date: 01/14/2015 07:04AM Subject: [openstack-dev] [horizon] function expressions vs

Re: [openstack-dev] [horizon] function expressions vs function declarations in JavaScript

2015-01-14 Thread Thai Q Tran
Wow, that IS interesting. No process required, just modify /horizon/doc/source/contributing.rst and submit a patch.-Matthew Farina m...@mattfarina.com wrote: -To: "OpenStack Development Mailing List (not for usage questions)" openstack-dev@lists.openstack.orgFrom: Matthew Farina

[openstack-dev] [horizon] function expressions vs function declarations in JavaScript

2015-01-14 Thread Matthew Farina
JavaScript has multiple ways to deal with functions. There are function declarations and function expressions (and named function expressions). In looking at some reviews and the current code I found some inconsistencies which leads me to ask, is there any guidance for handling this in Horizon? I

Re: [openstack-dev] [horizon] function expressions vs function declarations in JavaScript

2015-01-14 Thread Thai Q Tran
It was definitely an interesting the read, I never really noticed the subtle difference. Since then I have also read a few other thoughts on it.For me, function declarations can get convoluted very fast if not use correctly.Surely, you should never define functions inside of an if statement, and