Cmdlet
New-OfficeHtmlMarkdownOptions
Creates native HTML-to-Markdown import and writer settings without converting or writing files.
Syntax
New-OfficeHtmlMarkdownOptions
[-Base64ImageHandling <Include| Skip| SaveToFile>]
[-Base64ImageOutputDirectory <String>]
[-BaseOptions <HtmlMarkdownExportOptions>]
[-BaseUri <String>]
[-DropUnsupportedBlocks]
[-DropUnsupportedInlineHtml]
[-ImageRenderingMode <RichMarkdown| PortableMarkdown| Html>]
[-IncludeDocumentChrome]
[-LineEnding <LF| CRLF| CR>]
[-ListingCardMetadataMode <Preserve| SuppressInRepeatedCards>]
[-MaxInputCharacters <Int32>]
[-MaxTableExpandedColumns <Int32>]
[-Portable]
[-PreserveScriptsAndStyles]
[-UnorderedListMarker <-| *| +>]
[-WriteOptions <MarkdownSaveOptions>]
[-WriteProfile <OfficeIMO| Portable| HtmlImage>]
[<CommonParameters>]#Parameter set:
DefaultExamples
Convert HTML using a portable Markdown profile.
$options = New-OfficeHtmlMarkdownOptions -Portable -LineEnding LF
Convert-OfficeDocument -Path ./Report.html -To Markdown -OutputPath ./Report.md -Options $optionsParameters
- -Base64ImageHandling MarkdownHtmlBase64ImageHandling
- How data URI images are represented in Markdown.
- Possible values:
Include,Skip,SaveToFile - -Base64ImageOutputDirectory String
- Literal image extraction directory; creating options does not create it.
- -BaseOptions HtmlMarkdownExportOptions
- Native settings to copy before applying explicit changes.
- -BaseUri String
- Absolute base URI for relative links and images.
- -DropUnsupportedBlocks SwitchParameter
- Convert unsupported block elements to their child content instead of retaining raw HTML.
- -DropUnsupportedInlineHtml SwitchParameter
- Convert unsupported inline elements instead of retaining raw HTML.
- -ImageRenderingMode MarkdownImageRenderingMode
- How the Markdown writer serializes images.
- Possible values:
RichMarkdown,PortableMarkdown,Html - -IncludeDocumentChrome SwitchParameter
- Include the complete HTML document instead of only its body.
- -LineEnding OfficeLineEnding
- Output line endings.
- Possible values:
LF,CRLF,CR - -ListingCardMetadataMode MarkdownHtmlListingCardMetadataMode
- Preserve or suppress repeated listing-card metadata.
- Possible values:
Preserve,SuppressInRepeatedCards - -MaxInputCharacters Int32
- Maximum accepted HTML input characters; null removes a copied limit.
- -MaxTableExpandedColumns Int32
- Maximum columns after expanding HTML table spans.
- -Portable SwitchParameter
- Start with the native portable profile instead of the OfficeIMO profile.
- -PreserveScriptsAndStyles SwitchParameter
- Retain script and style elements in the generated Markdown.
- -UnorderedListMarker String
- Unordered list marker.
- Possible values:
-,*,+ - -WriteOptions MarkdownSaveOptions
- Native Markdown writer settings to copy.
- -WriteProfile OfficeMarkdownWriteProfile
- Start with a named Markdown writer profile.
- Possible values:
OfficeIMO,Portable,HtmlImage
Common Parameters
This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.
For more information, see about_CommonParameters.