まぬねこの足跡。。。

備忘録+たのしさ+ひっそりと

<head>: ヘッダー(文書メタデータ) 要素

概要

<head>: ヘッダー(文書メタデータ) 要素

・文書に関するメタデータ:題名、スクリプトスタイルシートなど

・html要素の次に配置。

使い方

書き方

<!DOCTYPE html>・・・「HTMLで記述」を宣言。
<html lang="ja">・・・DOCTYPE宣言の次 使用言語:日本語(ja)
  <head>・・・・・・・<html>タグの次
    <meta charset="UTF-8">・・・使用文字コード
    <meta http-equiv="X-UA-Compatible" content="IE=edge">・・・IE互換
    <meta name="viewport" content="width=device-width, initial-scale=1.0">・・・モバイル端ビューポート指定
    <meta name="description" content="この文章の説明">・・・ページ説明
    <title>タイトル</title>・・・ページタイトル
  </head>
    <body>・・・ページ本編

    </body>
</html>

参考

【MDNMDN Web Docs】<head>タグ:ヘッダー(文書メタデータ) 要素