思源笔记社区正在搭建中,现邀您共建
SiYuan Community is under construction. Join us to co-build.
Lutedeclare),没有实际的源代码。| Property | Type | Description |
|---|---|---|
WalkStop | number | #TODO |
WalkSkipChildren | number | #TODO |
WalkContinue | number | #TODO |
Version | string | #TODO |
Caret | string | #TODO |
Newpublic static New(): Lute;EChartsMindmapStrpublic static EChartsMindmapStr(text: string): string;NewNodeIDpublic static NewNodeID(): string;Sanitizepublic static Sanitize(html: string): string;EscapeHTMLStrpublic static EscapeHTMLStr(str: string): string;UnEscapeHTMLStrpublic static UnEscapeHTMLStr(str: string): string;GetHeadingIDpublic static GetHeadingID(node: ILuteNode): string;BlockDOM2Contentpublic static BlockDOM2Content(html: string): string;private constructor();BlockDOM2Contentpublic BlockDOM2Content(text: string): string;BlockDOM2EscapeMarkerContentpublic BlockDOM2EscapeMarkerContent(text: string): string;SetTextMarkpublic SetTextMark(enable: boolean): void;SetHeadingIDpublic SetHeadingID(enable: boolean): void;SetProtyleMarkNetImgpublic SetProtyleMarkNetImg(enable: boolean): void;SetSpellcheckpublic SetSpellcheck(enable: boolean): void;SetFileAnnotationRefpublic SetFileAnnotationRef(enable: boolean): void;SetSetextpublic SetSetext(enable: boolean): void;SetYamlFrontMatterpublic SetYamlFrontMatter(enable: boolean): void;SetChineseParagraphBeginningSpacepublic SetChineseParagraphBeginningSpace(enable: boolean): void;SetRenderListStylepublic SetRenderListStyle(enable: boolean): void;SetImgPathAllowSpacepublic SetImgPathAllowSpace(enable: boolean): void;SetKramdownIALpublic SetKramdownIAL(enable: boolean): void;BlockDOM2Mdpublic BlockDOM2Md(html: string): string;BlockDOM2StdMdpublic BlockDOM2StdMd(html: string): string;SetGitConflictpublic SetGitConflict(enable: boolean): void;SetSuperBlockpublic SetSuperBlock(enable: boolean): void;SetTagpublic SetTag(enable: boolean): void;SetMarkpublic SetMark(enable: boolean): void;SetSubpublic SetSub(enable: boolean): void;SetSuppublic SetSup(enable: boolean): void;SetBlockRefpublic SetBlockRef(enable: boolean): void;SetSanitizepublic SetSanitize(enable: boolean): void;lute.go文件中。[!WARNING]
根据官方描述,Lute 目前的实现存在一些漏洞,请不要依赖它来防御 XSS 攻击。
SetHeadingAnchorpublic SetHeadingAnchor(enable: boolean): void;SetImageLazyLoadingpublic SetImageLazyLoading(imagePath: string): void;SetInlineMathAllowDigitAfterOpenMarkerpublic SetInlineMathAllowDigitAfterOpenMarker(enable: boolean): void;SetToCpublic SetToC(enable: boolean): void;SetIndentCodeBlockpublic SetIndentCodeBlock(enable: boolean): void;SetParagraphBeginningSpacepublic SetParagraphBeginningSpace(enable: boolean): void;SetFootnotespublic SetFootnotes(enable: boolean): void;SetLinkRefpublic SetLinkRef(enable: boolean): void;SetEmojiSitepublic SetEmojiSite(emojiSite: string): void;PutEmojispublic PutEmojis(emojis: IObject): void;SpinBlockDOMpublic SpinBlockDOM(html: string): string;html可以是原来的块 html 文本,也可以是 Markdown 文本,因为其工作流程为:参数html转换为 Markdown 文本,转换为抽象语法树,生成返回值。/菜单新建块、在编辑器中输入 Markdown 标记文本(如在行首输入#)、在编辑器中输入回车等。Md2BlockDOMpublic Md2BlockDOM(html: string): string;SetProtyleWYSIWYGpublic SetProtyleWYSIWYG(wysiwyg: boolean): void;MarkdownStrpublic MarkdownStr(name: string, md: string): string;IsValidLinkDestpublic IsValidLinkDest(text: string): boolean;BlockDOM2InlineBlockDOMpublic BlockDOM2InlineBlockDOM(html: string): string;BlockDOM2HTMLpublic BlockDOM2HTML(html: string): string;