You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert
May 11, 2010 12:15 am | 43 Comments I’ve looked at a bunch of third party JavaScript snippets as part of my P3PC series. As I analyzed each of these snippets, I looked to see if scripts were being loaded dynamically. After all, this is a key ingredient for making third party content fast. It turns out nobody does dynamic loading the same way. I’d like to walk through some of the variations I found
Firefoxのclickイベントは、イベントリスナーの登録先がdocumentか要素かによって、中・右クリックも捕捉するかどうかが変わる。 /* Firefox 3.6.13 */ document.addEventListener('click', function (e) { alert(e.button); /* 左クリック、中クリック、右クリック すべて拾う */ }, false); document.body.addEventListener('click', function (e) { alert(e.button); /* 左クリックしか拾わない */ }, false); 他のブラウザではどうなるかも調べてみたけど、Firefoxのように登録ノードによって違いがでるブラウザはなかった。 document 要素ノード 左 中 右 左 中 右 IE8 ○ ○ × ○ ○
Show lines around each change Show the changes in full context Timestamp: Dec 9, 2010, 11:48:03 PM (15 years ago) Author: rniwa@webkit.org Message: 2010-12-09 Ryosuke Niwa <rniwa@webkit.org> Reviewed by Ojan Vafai. Make DOM Mutation Events Asynchronous https://bugs.webkit.org/show_bug.cgi?id=46936 Implemented DOM mutations events as scoped events. A scoped event is an event whose dispatch is don
SURGAVIP # Link Slot Pragmatic Gacor Malam Ini Modal Kecil Janji Maxwin Sekarang ! Selamat datang di SURGAVIP situs slot terpercaya dari server PG Soft ternama, banyak jenis permainan slot gacor dan mudah menang maxwin disini bersama surgavip. main dengan modal receh pulang dengan uang berlimpah. SURGAVIP dikenal sebagai situs terpercaya dengan koleksi lengkap game dari pg oft, provider yang udah
Mozillaでアクセシビリティ関連のQAを担当しているMarco Zeheが自身のBlogに “The importance of placement of HTML elements in a document” という記事を投稿していました。JavaScriptでモーダルダイアログなどを実現するものがありますが、実装方法によってアクセシビリティを著しく損ねることになるケースが紹介されています。 記事で例に挙げられていたのはThickBox。デモの写真やリンクをクリックするとダイアログが開くのですが、これは新たに生成したdivを文書の一番後ろに追加し、それをスタイルシートで調整するという実装が行われています。 表示上はなんら問題ない方法ですが、Zeheはこの「文書の一番後ろに追加する」ことに問題があると述べています。文書の最後に要素を追加してしまうと、内容の多いページにおいてはアンカー
Participate: GitHub whatwg/xhr (new issue, open issues) Chat on Matrix Commits: GitHub whatwg/xhr/commits Snapshot as of this commit @xhrstandard Tests: web-platform-tests xhr/ (ongoing work) Translations (non-normative): 日本語 简体中文 한국어 Abstract The XMLHttpRequest Standard defines an API that provides scripted client functionality for transferring data between a client and a server. 1. Introduction
最近javascriptを使ってクロスブラウザでDOM操作とかしてみたので,それで分かったことや残したいことを今のうちにまとめておきます. Ajaxについても書こうとしたけど時間やばくなってきたので次回まとめる. なお自分で発見したことはほとんどなく,ほぼWeb上のリソースを参考にして書きますが,あまりに多いので割愛します.申し訳ありません. Webすごい!すばらしい!! ■DOM要素のプロパティのブラウザによる違い DOM要素のプロパティはブラウザによってかなり違います. だからクロスブラウザでjavascriptをがしがし動かそうとするとすごく大変. なのでちょっとコツみたいなものをまとめます. ※使用したブラウザはIE8・Firefox3.6・Google Chrome8 dev版 要素のプロパティを調べるときはブラウザの開発者ツールを使う 私は「どの要素がどういうプロパティを持つか
【Javascript】要素.value=xxxx と 要素.setAttribute(“value”, “xxxx”) どっちを使う? https://developer.mozilla.org/ja/DOM/element.setAttribute setAttribute() を使ってある属性、XULやHTMLの特別な値、およびHTMLの選択領域を変更することは、属性がデフォルト値を特定している場合に一貫性なく働きます。現在の値にアクセスしたり、変更したりするにはプロパティを使用すべきです。例としては elt.setAttribute(‘value’, val) の代わりに elt.value を使用します。 さて?どういう意味でしょう? このようなリファレンスの記述を知らなくても、実際にやってみて不可解な現象に遭遇した方いるかもしれません。IEだけ使っていると出会ったことがないかも
The document discusses high-performance JavaScript and its impact on user experience, emphasizing that both UI updates and JavaScript execution cannot occur simultaneously on the browser's UI thread. It recommends limiting JavaScript execution time to no more than 50ms to maintain responsiveness and outlines techniques to optimize loading and execution, such as placing scripts at the bottom of the
IEでは以下のコードが動作しない。 hoge instanceof Node; hoge instanceof Element; 仕方ないのでJavascript:DOMオブジェクトかECMAオブジェクトかを判定する。: Script雑感を参考にして以下のような判定関数を作った。 if(typeof(Util) == "undefined") window.Util = {}; if(/*@cc_on!@*/false) { Util.isDomNode = function(obj) { if(!!obj && !(obj instanceof Object) && typeof(obj.nodeType) == "number") { try { obj.nodeType = obj.nodeType; } catch(e) { return true; } } return fals
What is DOMAssistant? The idea of DOMAssistant is to provide a simpler and more consistent way to script against the Document Object Model (DOM) in web browsers. The idea is that everything starts with the element(s) in question, selected through id or CSS selectors, and then perform various methods on it, such as adding or removing classes, events etc. Example code: $("#container input[type=text]
はてなグループの終了日を2020年1月31日(金)に決定しました 以下のエントリの通り、今年末を目処にはてなグループを終了予定である旨をお知らせしておりました。 2019年末を目処に、はてなグループの提供を終了する予定です - はてなグループ日記 このたび、正式に終了日を決定いたしましたので、以下の通りご確認ください。 終了日: 2020年1月31日(金) エクスポート希望申請期限:2020年1月31日(金) 終了日以降は、はてなグループの閲覧および投稿は行えません。日記のエクスポートが必要な方は以下の記事にしたがって手続きをしてください。 はてなグループに投稿された日記データのエクスポートについて - はてなグループ日記 ご利用のみなさまにはご迷惑をおかけいたしますが、どうぞよろしくお願いいたします。 2020-06-25 追記 はてなグループ日記のエクスポートデータは2020年2月28
I recently came across a jQuery plugin that claims to emulate the functionality of Object.prototype.watch, a method inherent in all objects that enables you to watch for a property change and run a function upon that change. Of course, this isn’t available in all implementations. IE, for example, doesn’t support this but has a DOM equivalent, onPropertyChange. Both methods are useful but their sli
最近のほとんどの JavaScript フレームワークには、 CSS セレクタによる DOM エレメントの取得機能が実装されています。複数の要素を柔軟な条件で取得できるので、 DOM ツリーの操作がシンプルに記述でき、とても便利です。しかし、単に CSS セレクタを使いたいだけなのに、フル機能のフレームワークを読み込むのはちょっと抵抗がありますよね。 そんな悩みを解決してくれるのが、本日ご紹介する Sizzle, Peppy という 2 つのライブラリです。これらは他のフレームワークに依存しない独立した CSS セレクタエンジンで、しかも jQuery 等の既存のエンジンより数倍高速に動作します。 unobtrusive な Web ウィジェットの開発や、独自フレームワークの開発に最適ですね。その他にも広範な用途に使えるでしょう。 以下でこれらのライブラリの使い方や動作速度等の検証結果を掲
Speeding up JavaScript: Working with the DOM Author: KeeKim Heng, Google Web Developer When working with Rich Internet Applications, we write JavaScript that updates the page by changing elements or adding new ones. This is done by working with the DOM, or Document Object Model, and how we do this can affect the speed of our applications. Working with the DOM can cause browser reflow, which is the
このページの最終更新日:2019年7月4日 JavaScript。主にWebページを作るのに使われるほか、現在ではさまざまなところで活躍しているプログラミング言語です。 このページはJavaScriptの中級講座です。最新鋭ではないかもしれませんが、読み進めれば大抵のものを自分で作れるようになることでしょう。 言い訳とJavaScriptの歴史 / 問い合わせ 最近の更新2017/10/05 全ページを手直ししました。十六章第六回を追加。2017/11/9 十六章第二十一回・十六章第二十二回を追加。2017/12/2 十七章第三回・十七章第四回を追加。2017/12/3 十七章第五回・十七章第六回・十七章第七回を追加。概要コンテンツは第一篇と第二篇に分かれています。 JavaScriptは昔からWebページに動きを与えるものとして用いられてきましたが、第一篇ではそのような、昔からあるJav
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く