diff options
author | Peter Bengtsson <mail@peterbe.com> | 2020-12-08 14:40:17 -0500 |
---|---|---|
committer | Peter Bengtsson <mail@peterbe.com> | 2020-12-08 14:40:17 -0500 |
commit | 33058f2b292b3a581333bdfb21b8f671898c5060 (patch) | |
tree | 51c3e392513ec574331b2d3f85c394445ea803c6 /files/ja/glossary/jquery/index.html | |
parent | 8b66d724f7caf0157093fb09cfec8fbd0c6ad50a (diff) | |
download | translated-content-33058f2b292b3a581333bdfb21b8f671898c5060.tar.gz translated-content-33058f2b292b3a581333bdfb21b8f671898c5060.tar.bz2 translated-content-33058f2b292b3a581333bdfb21b8f671898c5060.zip |
initial commit
Diffstat (limited to 'files/ja/glossary/jquery/index.html')
-rw-r--r-- | files/ja/glossary/jquery/index.html | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/files/ja/glossary/jquery/index.html b/files/ja/glossary/jquery/index.html new file mode 100644 index 0000000000..1d31b65d5f --- /dev/null +++ b/files/ja/glossary/jquery/index.html @@ -0,0 +1,46 @@ +--- +title: jQuery +slug: Glossary/jQuery +tags: + - Glossary + - JQuery + - JavaScript +translation_of: Glossary/jQuery +--- +<p><span class="seoSummary"><strong>jQuery</strong> は {{Glossary("JavaScript")}} {{Glossary("Library", "ライブラリー")}} であり、{{Glossary("DOM")}} 操作を簡単にすること、{{Glossary("AJAX")}} 呼び出し、{{Glossary("Event", "イベント")}} ハンドリングに注力しています。</span></p> + +<p>jQuery は <code>$(selector).action()</code> というフォーマットを使って要素をイベントに割り当てます。詳しく説明すると、<code>$(selector)</code> が jQuery を呼び出して <code>selector</code> 要素を選択し、 <code>.action()</code>というイベント {{Glossary("API")}} に割り当てます。</p> + +<pre class="brush: js notranslate">$(document).ready(function(){ + alert("Hello World!"); + $("#blackBox").hide(); +});</pre> + +<p>上のコードは下のコードと同じ関数を実行します:</p> + +<pre class="brush: js notranslate">window.onload = function() { + alert("Hello World!"); + document.getElementById("blackBox").style.display = "none"; +};</pre> + +<p>または</p> + +<pre class="brush: js notranslate">window.addEventListener("load", () => { + alert("Hello World!"); + document.getElementById("blackBox").style.display = "none"; +});</pre> + +<h2 id="Learn_more" name="Learn_more">関連項目</h2> + +<h3 id="General_knowledge" name="General_knowledge">一般知識</h3> + +<ul> + <li>Wikipedia の {{Interwiki("wikipedia", "jQuery")}}</li> + <li><a href="https://jquery.com/">jQuery Official Website</a></li> +</ul> + +<h3 id="Technical_information" name="Technical_information">技術情報</h3> + +<ul> + <li><a href="https://api.jquery.com/">API リファレンス文書</a><a href="https://api.jquery.com/"> </a></li> +</ul> |