Skip to content

Commit 5c8ce6e

Browse files
author
Katrina Owen
committed
Add default introductory code example
Instead of having logic for a fallback in the backend, we're choosing a default for the snippet file. For tracks that have core exercises, we pick the first core exercise. For tracks without these, we pick the first exercise listed in the config.
1 parent b1a8507 commit 5c8ce6e

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

docs/SNIPPET.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
function! Hello(...) abort
2+
let name = (a:0 == 1 ? a:1 : 'World')
3+
return 'Hello, ' . name . '!'
4+
endfunction

0 commit comments

Comments
 (0)