Get to know MDN better
このページはコミュニティーの尽力で英語から翻訳されました。MDN Web Docs コミュニティーについてもっと知り、仲間になるにはこちらから。
This feature is well established and works across many devices and browser versions. It’s been available across browsers since 2017年10月.
* Some parts of this feature may have varying levels of support.
WebAssembly.validate() 関数は WebAssembly バイナリーコードの型付き配列を検証し、そのバイト列が有効な wasm モジュールか (true)、そうでないか (false) を返します。
検証する WebAssembly バイナリーコードを含む型付き配列または ArrayBuffer。
有効な wasm モジュールであるか (true)、そうでないか (false) を示す論理値です。
bufferSource が型付き配列または ArrayBuffer でない場合、TypeError が発生します。
以下の例 (validate.html のソースコードと動作例 をご確認ください) は .wasm モジュールを読み取って型付き配列に変換します。次に、 validate() メソッドを使用してモジュールが有効かどうかをチェックします。
| WebAssembly JavaScript Interface # dom-webassembly-validate |
Enable JavaScript to view this browser compatibility table.
This page was last modified on 2025年3月21日 by MDN contributors.
Your blueprint for a better internet.
Visit Mozilla Corporation’s not-for-profit parent, the Mozilla Foundation.
Portions of this content are ©1998–2026 by individual mozilla.org contributors. Content available under a Creative Commons license.