Skip to content
| Marketplace
Sign in
Visual Studio Code>Formatters>Markdown Table TSVNew to Visual Studio Code? Get it now.
Markdown Table TSV

Markdown Table TSV

Expression Inc.

|
1 install
| (0) | Free
Paste TSV (e.g. copied from Excel) as a Markdown table, and copy a Markdown table as TSV.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Markdown Table TSV

日本語

Paste TSV copied from Excel or Google Sheets as a Markdown table, and copy a Markdown table as TSV to paste back into a spreadsheet.

Commands

Command Action
Markdown Table TSV: Paste TSV as Markdown Table Converts the TSV in the clipboard to a Markdown table and pastes it at the cursor (replacing the selection; at every cursor with multiple cursors)
Markdown Table TSV: Copy Selected Markdown Table as TSV Copies the table rows on the selected lines as TSV. Without a selection, does the same as Copy Whole Markdown Table as TSV
Markdown Table TSV: Copy Whole Markdown Table as TSV Selects the table at the cursor (or the first table below the cursor) and copies it as TSV
Markdown Table TSV: Select Next Markdown Table Selects the table at the cursor (or the first table below the cursor). Run it again to select the next table

Command names and messages are shown in English or Japanese according to the VS Code display language. No keys are assigned by default. Assign them in Keyboard Shortcuts if you like.

TSV to Markdown

  • The first row becomes the header.
  • Columns are aligned by display width, counting full-width characters (CJK) and emoji as 2.
  • Columns that are empty in every row are removed. Leading and trailing whitespace in cells is removed.
  • Quoted cells (as Excel copies cells containing line breaks) are supported. Line breaks in cells become <br>, and | becomes \|.
No	Item	Note
1	Notice	"Line 1
Line 2"

↓

| No  | Item   | Note             |
| --- | ------ | ---------------- |
| 1   | Notice | Line 1<br>Line 2 |

Markdown to TSV

  • Lines that start and end with | (ignoring surrounding whitespace) are treated as table rows. The separator row (| --- | :-: |) is skipped.
  • \| is restored to |, and <br> to a line break. Cells containing line breaks or tabs, and cells starting with ", are quoted so that spreadsheets read them as one cell.

Limitations

  • Tables without leading and trailing | are not recognized.
  • Characters whose width depends on the font (East Asian Ambiguous, such as ○ or ※) are counted as 1.

日本語

Excel や Google スプレッドシートからコピーした TSV を Markdown の表にして貼り付け、Markdown の表を TSV にしてコピーする(スプレッドシートに貼り戻せる)拡張機能。

コマンド

コマンド 動作
Markdown Table TSV: TSV を Markdown の表として貼り付け クリップボードの TSV を Markdown の表にして、カーソルの位置に貼り付ける(選択範囲は置き換える。複数カーソルならそれぞれに貼る)
Markdown Table TSV: 選択した Markdown の表を TSV としてコピー 選択範囲にかかる行のうち、表の行を TSV にしてコピーする。選択範囲がなければ「Markdown の表全体を TSV としてコピー」と同じ
Markdown Table TSV: Markdown の表全体を TSV としてコピー カーソルのある表(なければカーソルより下で最初の表)を選択し、TSV にしてコピーする
Markdown Table TSV: 次の Markdown の表を選択 カーソルのある表(なければカーソルより下で最初の表)を選択する。もう一度実行すると次の表を選択する

コマンド名とメッセージは、VS Code の表示言語に合わせて日本語か英語で表示する。キーは割り当てていない。必要ならキーボードショートカットの設定から割り当てる。

TSV → Markdown

  • 1 行目を見出しにする。
  • 列幅は表示幅で揃える。全角の文字と絵文字は 2 文字分として数える。
  • すべての行で空の列は除く。セルの前後の空白は取る。
  • 引用符で囲まれたセル(Excel が改行を含むセルをコピーしたときの形)を読める。セルの中の改行は <br> に、| は \| にする。

Markdown → TSV

  • 前後の空白を除いて | で始まり | で終わる行を、表の行とする。区切り行(| --- | :-: |)は除く。
  • \| は | に、<br> は改行に戻す。改行やタブを含むセルと " で始まるセルは、スプレッドシートが 1 つのセルとして読めるよう引用符で囲む。

制限

  • 前後に | のない表は認識しない。
  • フォントによって幅が変わる文字(○ や ※ などの East Asian Ambiguous)は 1 文字分として数える。

開発

npm install                  # typescript と @types/vscode だけ
npm test                     # ビルドして、変換と表の検出のテストを実行(node:test)
npm run package              # .vsix を作成(vsce は npx でその都度取得)
npm run icon                 # images/icon.svg を images/icon.png(256×256)に書き出す(sharp-cli は npx でその都度取得)
npm run publish:marketplace  # VS Code Marketplace に公開(事前に vsce login ExpressionInc)

F5 で起動する開発ホストは test_data を開く。

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
  • Your Privacy Choices
  • Consumer Health Privacy
© 2026 Microsoft