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
Toggle dark mode How do I copy an object in JavaScript? It’s a simple question, without a simple answer. Chinese translation: 中文版 Russian translation: русском Uzbek translation: O'zbek Call by reference JavaScript passes everything by reference. In case you don’t know what that means, here’s an example: function mutate(obj) { obj.a = true; } const obj = {a: false}; mutate(obj) console.log(obj.a);
はじめに この記事はChromium Browser Advent Calendar 2017の22日目の記事になります。 ChromiumプロジェクトでFetch APIやService Worker周りを担当しているhoroです。つい先日、Microsoft Edgeの開発者版やSafariの開発者版でもService Workerが使えるようになったそうで、非常に嬉しい限りです。 さて、今回は、Service Workerにも少し関係がある、JavaScriptのコードキャッシュについてです。 コードキャッシュとは この資料によると、現実世界のWebページでは、V8の実行時間のうちJavaScriptのパースに15-20%の時間がかかっていると言われています。 そこで、Chromiumでは、頻繁に読み込まれるJavaScriptファイルに関して、パース処理によって生成されるバイトコー
ゲームなどのコンテンツにおいて、「当たり判定」から逃れることはできません。オブジェクトとオブジェクトが衝突したかどうかという判定は、インタラクティブコンテンツにおいて最も重要な部分になるからです。 当たり判定の実装自体は難しくありません。ですが、素朴な実装ですと、対象となるオブジェクトが大量である場合に、十分なパフォーマンスが出ません。これはオブジェクトの多い、現代的なゲームでしたり、弾幕シューティングなどを作るときに大きな障害となります。 この記事では、大量のオブジェクトの当たり判定を処理する、効率的な方法について紹介します。 まずは素朴に実装してみる 当たり判定の処理を語るには、ある程度ゲームの骨組みのようなものが必要になってきます。もちろんクラスなどを使わないベタ書きでもよいのですが、大変読みにくくなってしまいます。ですので、今回は、まず簡易的なゲームエンジンのようなものを作って、そ
The zero configuration build tool for the web. JavaScript. CSS. HTML. TypeScript. React. images. SASS. SVG. Vue. libraries. Less. CoffeeScript. Node. Stylus. Pug. Electron. Elm. WebGL. extensions. GraphQL. MDX. XML. Parcel combines a great out-of-the-box development experience with a scalable architecture that can take your project from just getting started to massive production application.
Project Tofino is a browser interaction experiment. The kinds of things we use browsers for on PCs and mobile devices are different than they were when the current "tabs across the top" browsers were designed. We believe we can do a lot better by focusing on the tasks and activities users engage browsers for. Project Tofino is one of our explorations. This project is extremely immature. It's curre
I've been working on the web since I was a small child all the way through to the haggard old man I am to day. However, the web still continues to surprise me. Turns out, mouse events don't fire when the pointer is over disabled form elements, except in Firefox. Serious? Serious. Give it a go. Move the mouse from the blue area below into the disabled button: It's not like the disabled button eleme
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く