iceshrimp-legacy/src/docs/zh-TW/pages.md
syuilo 0343c5e692
New Crowdin updates (#7095)
* New translations ja-JP.yml (German)

* New translations ja-JP.yml (Korean)

* New translations ja-JP.yml (Korean)

* New translations ja-JP.yml (Korean)

* New translations ja-JP.yml (Korean)

* New translations ja-JP.yml (Korean)

* New translations ja-JP.yml (Korean)

* New translations ja-JP.yml (Korean)

* New translations ja-JP.yml (Korean)

* New translations aiscript.md (Korean)

* New translations ja-JP.yml (French)

* New translations ja-JP.yml (French)

* New translations ja-JP.yml (French)

* New translations ja-JP.yml (French)

* New translations ja-JP.yml (French)

* New translations ja-JP.yml (French)

* New translations ja-JP.yml (French)

* New translations ja-JP.yml (French)

* New translations ja-JP.yml (French)

* New translations ja-JP.yml (French)

* New translations ja-JP.yml (French)

* New translations ja-JP.yml (English)

* New translations ja-JP.yml (French)

* New translations ja-JP.yml (French)

* New translations stream.md (Chinese Simplified)

* New translations ja-JP.yml (Chinese Simplified)

* New translations stream.md (Chinese Simplified)

* New translations stream.md (Chinese Simplified)

* New translations stream.md (Chinese Simplified)

* New translations ja-JP.yml (Chinese Traditional)

* New translations theme.md (Chinese Traditional)

* New translations theme.md (Chinese Traditional)

* New translations theme.md (Chinese Traditional)

* New translations theme.md (Chinese Traditional)

* New translations theme.md (Chinese Traditional)

* New translations ja-JP.yml (Chinese Traditional)

* New translations mfm.md (Chinese Traditional)

* New translations keyboard-shortcut.md (Chinese Traditional)

* New translations keyboard-shortcut.md (Chinese Traditional)

* New translations ja-JP.yml (Chinese Traditional)

* New translations keyboard-shortcut.md (Chinese Traditional)

* New translations pages.md (Chinese Traditional)

* New translations timelines.md (Chinese Traditional)

* New translations ja-JP.yml (Polish)

* New translations ja-JP.yml (Polish)

* New translations ja-JP.yml (Polish)

* New translations ja-JP.yml (Polish)

* New translations ja-JP.yml (Polish)

* New translations keyboard-shortcut.md (Polish)

* New translations ja-JP.yml (Polish)

* New translations ja-JP.yml (Polish)

* New translations ja-JP.yml (Korean)

* New translations ja-JP.yml (Polish)

* New translations ja-JP.yml (Korean)

* New translations ja-JP.yml (Polish)

* New translations ja-JP.yml (Polish)

* New translations ja-JP.yml (Arabic)
2021-01-23 19:58:07 +09:00

1.6 KiB

頁面

變數

変数を使うことで動的なページを作成できます。テキスト内で { 変数名 } と書くとそこに変数の値を埋め込めます。例えば Hello { thing } world! というテキストで、変数(thing)の値が ai だった場合、テキストは Hello ai world! になります。

変数の評価(値を算出すること)は上から下に行われるので、ある変数の中で自分より下の変数を参照することはできません。例えば上から A、B、C と3つの変数を定義したとき、Cの中でABを参照することはできますが、Aの中でBCを参照することはできません。

ユーザーからの入力を受け取るには、ページに「ユーザー入力」ブロックを設置し、「変数名」に入力を格納したい変数名を設定します(変数は自動で作成されます)。その変数を使ってユーザー入力に応じた動作を行えます。

関数を使うと、値の算出処理を再利用可能な形にまとめることができます。関数を作るには、「関数」タイプの変数を作成します。関数にはスロット(引数)を設定することができ、スロットの値は関数内で変数として利用可能です。また、関数を引数に取る関数(高階関数と呼ばれます)も存在します。関数は予め定義しておくほかに、このような高階関数のスロットに即席でセットすることもできます。