-- fastn.dependency: fastn-community.github.io/code-block
Basic code example
Input
-- cb.code:
lang: java
if (condition) {
// code block
statement1;
statement2;
// ...
}
Output
if (condition) {
// code block
statement1;
statement2;
// ...
}
Download code block in a file
Input
-- cb.code:
lang: java
download: example.java
if (condition) {
// code block
statement1;
statement2;
// ...
}
Output
if (condition) {
// code block
statement1;
statement2;
// ...
}
Copy false
Input
-- cb.code:
lang: java
copy: false
if (condition) {
// code block
statement1;
statement2;
// ...
}
Output
if (condition) {
// code block
statement1;
statement2;
// ...
}
ftd
lang example
Input
-- cb.code:
lang: ftd
-- ftd.text: Hello I am fastn lang
role: $inherited.types.copy-regular
color: $inherited.colors.text-strong
Output
-- ftd.text: Hello I am fastn lang
role: $inherited.types.copy-regular
color: $inherited.colors.text-strong