Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit2571711

Browse files
committed
parse hints with '-'
Signed-off-by: shmck <shawn.j.mckay@gmail.com>
1 parent44ba473 commit2571711

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

‎src/utils/parse.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ export function parseMdContent(md: string): TutorialFrame | never {
8686
consthintDetectRegex=/^(#{4}\sHINTS[\n\r]+([\*|\-]\s(?<hintContent>[^]*))[\n\r]+)+/;
8787
consthintMatch=section.match(hintDetectRegex);
8888
if(!!hintMatch){
89-
consthintItemRegex=/[\n\r]+\*\s/;
89+
consthintItemRegex=/[\n\r]+[\*|\-]\s/;
9090
consthints=section
9191
.split(hintItemRegex)
9292
.slice(1)// remove #### HINTS

‎tests/parse.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1000,7 +1000,7 @@ The first step
10001000
expect(result.levels).toEqual(expected.levels);
10011001
});
10021002

1003-
xit("should parse hints for a step with '-'",()=>{
1003+
it("should parse hints for a step with '-'",()=>{
10041004
constmd=`# Title
10051005
10061006
Description.

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp