File tree Expand file tree Collapse file tree 1 file changed +4
-6
lines changed Expand file tree Collapse file tree 1 file changed +4
-6
lines changed Original file line number Diff line number Diff line change @@ -41,15 +41,13 @@ export function parseMdContent(md: string): TutorialFrame | never {
4141 const summaryMatch = parts
4242 . shift ( )
4343 . match ( / ^ # \s (?< tutorialTitle > .* ) [ \n \r ] + (?< tutorialDescription > [ ^ ] * ) / ) ;
44- if ( ! summaryMatch . groups . tutorialTitle ) {
45- throw new Error ( "Missing tutorial title" ) ;
44+ if ( summaryMatch . groups . tutorialTitle ) {
45+ mdContent . summary . title = summaryMatch . groups . tutorialTitle . trim ( ) ;
4646 }
47- mdContent . summary . title = summaryMatch . groups . tutorialTitle . trim ( ) ;
4847
49- if ( ! summaryMatch . groups . tutorialDescription ) {
50- throw new Error ( "Missing tutorial summary description" ) ;
48+ if ( summaryMatch . groups . tutorialDescription ) {
49+ mdContent . summary . description = summaryMatch . groups . tutorialDescription . trim ( ) ;
5150 }
52- mdContent . summary . description = summaryMatch . groups . tutorialDescription . trim ( ) ;
5351
5452 // Identify each part of the content
5553 parts . forEach ( ( section : string ) => {
You can’t perform that action at this time.
0 commit comments