I’d like to use front-end javascript functions on a HTML file -eg. reading a property from the file etc. Is this possible in node? Thanks.
Asked
Active
Viewed 427 times
0
-
1There are various html parsers written in JS. CheerioJS is one of them – Jonas Wilms May 27 '19 at 14:40
1 Answers
-1
There are plenty of libraries that handle it for you already. Probably one of the most popular may be:
Both will allow you to use DOM features(like document.getElementByID()) from you Node JS. Get yourself familiar with the documentation and enjoy using. If you meant the opposite(using node js features in you html/js app), then you need some backend server.
Remember to search for already answered questions, I was able to find that with no ease.
Regards.

Mike Sar
- 107
- 9