リファレンス · 読み、表記、英語の意味、漢字、ローマ字から単語を引く
studyListText関数
リファレンスの説明と例は英語です。見出しと目次は日本語です。
A study list as text: csv has a header line and quotes what needs it, for a spreadsheet; tsv has no header and tabs, to paste
into a spreadsheet or to import into a flashcard program. Lines end with a line feed; an empty level or grade is an empty field.
インポート
import { studyListText } from "@johnmorrisdotca/jisho/words";
定義
function studyListText(rows: readonly StudyRow[], format: "csv" | "tsv"): string
引数
| 名前 | 型 | 説明 |
|---|---|---|
rows | readonly StudyRow[] | From |
format | "csv" | "tsv" |
|
戻り値
string
The text, ending in a line feed, or empty for no rows.
例
import { studyListText } from "@johnmorrisdotca/jisho/words";
const row = { written: "水", reading: "みず", meaning: "water", level: "N5", grade: 1, count: 1, example: "水" } as const;
console.log(studyListText([row], "csv")); // written,reading,meaning,level,grade,count,example ...written,reading,meaning,level,grade,count,example
水,みず,water,N5,1,1,水出力(このページを作ったときに実行した結果)
この日本語は、まだ日本語を母語とする方の確認を受けていません。訂正を歓迎します。