htmldoc-ext
Usage
Extract annotation content.
You are free to specify the annotation.
const htmldoc = const filepath = './index.html'
<!-- @description descriptiondescription description descriptiondescription @testtest notenotenote @date 2018/08/26 @url - https://111.com - https://222.com - https://333.com @name index.html @list ・1111111 ・2222222 ・3333333--> ./index.html
Single item
let test = htmldoccontentfilepath 'testtest'// -> notenotenote let description = htmldoccontentfilepath 'description'// -> descriptiondescription\ndescription\ndescriptiondescription let date = htmldoccontentfilepath 'date'// -> 2018/08/26
Multiple items
let url = htmldoc// -> ["https://111.com", "https://222.com", "https://333.com"] let list = htmldoc// -> ["1111111", "2222222", "3333333"]
Convert to Preferred list style
let array = "1111111" "2222222" "3333333" let circleList = htmldoc// -> "・1111111\n・2222222\n・3333333" let arrowList = htmldoc// -> "> 1111111\n> 2222222\n> 3333333"