简体   繁体   中英

how to get web api in nodejs (without lib)

I am making a module that converts html to json in node environment. I would like to know how to access web browser api from node. How can I access document object with nodejs only without libraries such as cheerio and jsdom? (I used Google Translate, sorry)

Node.js does not have built-in support for rendering HTML documents.

It doesn't execute JavaScript that it extracts from <script> elements inside an HTML document.

It has no native document object.

If you want one you either need to build it yourself or use a third-party library.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM