HTML5から導入された data-* 属性は、JavaScriptに渡したいデータをHTML側に埋め込んでおくための標準的な方法です。 getAttribute ('data-userid') のようにして値を取得することで、HTMLとJavaScriptの間でスムーズにデータの受け渡しを行うことができます。
The HTML code is in the index.html file. The JavaScript code is in the index.js file.
The HTML code is in the index.html file. The JavaScript code is in the index.js file.
一部の結果でアクセス不可の可能性があるため、非表示になっています。
アクセス不可の結果を表示する