Skip to content

Commit 0d3fa80

Browse files
authored
Include buttons in html-to-markdown conversion (#38)
1 parent ceec386 commit 0d3fa80

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

src/converters.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -251,6 +251,7 @@ function tidyHtml(html: string, includeImages: boolean): string {
251251
// - footer (might contain company info)
252252
// - img, picture, figure (if includeImages is false)
253253
// - option, label, select (this can present product options and titles)
254+
// - button (this can present product metadata, e.g. number of reviews)
254255
const manuallyCleanedElements = [
255256
// important
256257
"aside",
@@ -272,7 +273,7 @@ function tidyHtml(html: string, includeImages: boolean): string {
272273
// secondary
273274
"area",
274275
"blink",
275-
"button",
276+
// "button",
276277
"datalist",
277278
"dialog",
278279
"frame",

test-data

Submodule test-data updated 42 files

0 commit comments

Comments
 (0)