Methods
WDataHtmlMinify(h, optopt) → {String}
- Description:
壓縮HTML
- Source:
Example
let hin = `
<html>
<head></head>
<body>abc</body>
</html>
`
let hout = wdhm(hin)
console.log(hout)
// => <html><head></head><body>abc</body></html>
Parameters:
Name | Type | Attributes | Default | Description |
---|---|---|---|---|
h |
String | 輸入HTML字串 |
||
opt |
Object |
<optional> |
{}
|
輸入設定物件,預設{} |
Returns:
回傳Promise,resolve回傳ltdt(各數據列為物件陣列),reject回傳錯誤訊息
- Type
- String