File tree Expand file tree Collapse file tree 3 files changed +7
-17
lines changed
fixtures/doctype-quirksmode-ibm Expand file tree Collapse file tree 3 files changed +7
-17
lines changed Original file line number Diff line number Diff line change @@ -100,16 +100,12 @@ function root(node, ctx) {
100100/**
101101 * Create a `doctype`.
102102 *
103- * @param {HastDoctype } node
103+ * @param {HastDoctype } _
104104 * @param {Context } ctx
105105 * @returns {DocumentType }
106106 */
107- function doctype ( node , { doc} ) {
108- return doc . implementation . createDocumentType (
109- node . name || 'html' ,
110- node . public || '' ,
111- node . system || ''
112- )
107+ function doctype ( _ , { doc} ) {
108+ return doc . implementation . createDocumentType ( 'html' , '' , '' )
113109}
114110
115111/**
Original file line number Diff line number Diff line change 1- <!DOCTYPE html SYSTEM "http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd" > < html > < head > </ head > < body > </ body > </ html >
1+ <!DOCTYPE html> < html > < head > </ head > < body > </ body > </ html >
Original file line number Diff line number Diff line change @@ -165,15 +165,9 @@ test('hast-util-to-dom', (t) => {
165165 )
166166
167167 t . equal (
168- serializeNodeToHtmlString (
169- toDom ( {
170- type : 'doctype' ,
171- name : 'html' ,
172- public : null ,
173- system : 'http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd'
174- } )
175- ) ,
176- '<!DOCTYPE html SYSTEM "http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd">' ,
168+ // @ts -ignore hast types out of date.
169+ serializeNodeToHtmlString ( toDom ( { type : 'doctype' } ) ) ,
170+ '<!DOCTYPE html>' ,
177171 'creates a doctype node'
178172 )
179173
You can’t perform that action at this time.
0 commit comments