HTML

QuackJSUtils.HTML

A class for creating HTML pages utilizing jsdom and showdown.

Constructors

constructor

new HTML(html?)

Creates an instance of HTML.

Parameters

NameTypeDefault valueDescription

html

string

'<!DOCTYPE html><html><body></body></html>'

The base HTML to be used thoughout the object.

Defined in

src/modules/html.ts:16

Properties

DOM

DOM: JSDOM

Defined in

src/modules/html.ts:9

Accessors

document

get document(): Document

A getter for the document from the DOM.

readonly

Returns

Document

Defined in

src/modules/html.ts:58

Methods

ExportToHTML

ExportToHTML(): string

This method will export the DOM to a string containing the minified HTML.

Returns

string

The minified HTML from the DOM.

Defined in

src/modules/html.ts:36


toString

toString(): string

This method will return a string representation of the HTML class.

Returns

string

The string representation of the HTML class.

Defined in

src/modules/html.ts:49


ConvertMarkdownToHTML

Static ConvertMarkdownToHTML(markdown): string

A function for converting Markdown code to HTML code.

Parameters

NameTypeDescription

markdown

string

The Markdown code to be converted.

Returns

string

The converted HTML from Markdown.

Defined in

src/modules/html.ts:26

Last updated