3
JavaScriptが「;」で始まる必要があるのはなぜですか?
最近、ウェブ上の多くのJavaScriptファイル;がコメントセクションの直後から始まることに気づきました。 たとえば、このjQueryプラグインのコードは次で始まります。 /** * jQuery.ScrollTo * Copyright (c) 2007-2008 Ariel Flesler - aflesler(at)gmail(dot)com | http://flesler.blogspot.com * Dual licensed under MIT and GPL. * Date: 9/11/2008 .... skipping several lines for brevity... * * @desc Scroll on both axes, to different values * @example $('div').scrollTo( { top: 300, left:'+=200' }, { …