markmap / markmap-vscode

Integrate markmap into VSCode
https://marketplace.visualstudio.com/items?itemName=gera2ld.markmap-vscode
MIT License
228 stars 22 forks source link

CRLF is not supported when parsing frontmatter #41

Closed kebuAAA closed 1 year ago

kebuAAA commented 2 years ago

I have read the guide but I still don't know where I should put my frontmatter. I try to put it in my markdown files but it seems not to work, Can you tell me how to configure the settings in detail? I really need this amazing extension!

gera2ld commented 2 years ago

Either add this to the beginning of your Markdown file (note the markmap: namespace):

---
markmap:
  colorFreezeLevel: 2
---

Or this to the Default Options of your extension settings:

{
  "colorFreezeLevel": 2
}

For example this is what I got with README.md of this repo:

image

Please let me know if you think the doc is not clear enough.

kebuAAA commented 2 years ago

I have done as what you said just now. The following code is in my md file.

---
markmap:
    colorFreezeLevel: 3
    initialExpandLevel: 1
---

# markmap

## Links

- <https://markmap.js.org/>
- [GitHub](https://github.com/gera2ld/markmap)

## Related Projects

- [coc-markmap](https://github.com/gera2ld/coc-markmap)
- [gatsby-remark-markmap](https://github.com/gera2ld/gatsby-remark-markmap)

## Features

- links
- **strong** ~~del~~ *italic* ==highlight==
- multiline
  text
- `inline code`
-
    ```js
    console.log('code block');
gera2ld commented 2 years ago

I guess your end of line sequence is CRLF? Only LF is supported at the moment, let me fix this.

kebuAAA commented 2 years ago

I guess your end of line sequence is CRLF? Only LF is supported at the moment, let me fix this.

Yeah, you are right, I change the end of line sequence and now the extension works well. Thank you very much.

fanlushuai commented 1 year ago

It's time to release @gera2ld