0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

Markdown記法を実際に試してみる

Last updated at Posted at 2024-12-23

Markdown記法チートシートを見つけました

ちなみに以下です.

Markdown(マークダウン)とは

簡単な記号を使って文章の構造や装飾を指定できるマークアップ言語です.マークアップ言語とは文章の構造や修飾情報などをテキストファイルに記述するための言語で,文章にタグや記号を付けてコンピューターに認識させて文書の構造を定義する役割を担っているのだそうです.

「ブログを書くときに使える装飾を記号で表現できる」ものです.

どのくらいあるのか

Markdownの種類を数えてみると,いっぱいありました.
ひとつづつ見てみます.

  • Codeの挿入

    Code spans 「`」を1つでコードを囲むと(コード)

    Code blocks 「`」を3つでコードを囲むと(python test.pyとか)

    例えば

    python test.py
     print('hello, world')
    


  • Format Text
    Headings  「#」で見出し
    Strikethrough 「~~」で囲むと打消し線
    Details  「<>」を付けた「detalis」で囲むと折りたたみ
    Note  「:::」で囲みnote info / note warn / note aertを付けて補足説明

  • Lists
    Bullet List 文頭に* + -を付けると順序なしリスト
    Ordered List 文頭に数字.をつけると番号付きリスト
    Description List HTMLの<dl>タグを付けると説明リスト
    ※ ちなみにTabキーでインデントすると組み合わせでネストできます

    • aaa
      1. bbb
      2. ccc

  • Checkbox  - [] タスク1で未チェック,- [x] タスク2で済みチェック

  • Blockquotes  文頭に>を置くと引用

  • Horizontal rules  * * ****- - -で水平線

  • Links [リンクテキスト](URL "タイトル")でタイトル付きのリンク

  • Images ![代替テキスト](画像のURL "画像タイトル")で画像埋め込み
    <img width="表示幅" alt="ファイル名" src="URL">で大きさ指定の画像埋め込み

  • テーブル 3x2などと入力する.前後に空行必要.:-::--:で右左寄せ
    例えば3x3などといれると,以下のように表示される

    1 2 3
    a a a
    a a a


  • 数式の挿入 `を3つで囲みmathを付けて数式挿入

  • 目次(TOC)の自動挿入 記事内の見出しを元に自動生成し,右に自動挿入される

  • 脚注 本文中に[^1][^example]

  • 絵文字 文頭\:と文尾:でkissing_closed_eyesを囲み絵文字埋め込み

  • リンクカード URLの前後を空行に

  • ダイアグラム `三つと文頭にplantuml.mermaidでも表示可

  • コンテンツの埋め込み 別サイト

  • コマンド補完機能 /コマンドを使うことで特定の操作や機能を呼び出せる

  • その他

  1. Markdownの無効化: \をMarkdownの前に入れる

  2. ボールドが** **で,イタリックが_ _

  3. 改行: <br \><br> </br>

  4. 文字色の変更: <font color="Red">テキスト</font>
    yey = gray
    yey = purple
    yey = emerar
    yey = ewef
    yey = whiteblue
    yey = green

    ??

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?