operators - || in javascript -


can please tell me || doing here

(function() { window.myapp = window.myapp || {}; window.myapp.lang = window.myapp.lang || {}; myapp.lang.extend = function(subclass, superclass) { subclass.prototype = new superclass(); }; })(); 

window.myapp = window.myapp || {}; 

it means: create window.myapp empty object if not exist.


Comments

Popular posts from this blog

delphi - How to convert bitmaps to video? -

jasper reports - Fixed header in Excel using JasperReports -

python - ('The SQL contains 0 parameter markers, but 50 parameters were supplied', 'HY000') or TypeError: 'tuple' object is not callable -