[SOLVED] How to retrieve data from HTM file and convert to json using in Javascript (Vue)


This Content is from Stack Overflow. Question asked by Chiu

I’m trying to upload a HTM file using in Vue. The data is actually a styled table using , , etc…

My question is that, is it possible to filter out the tabulated data in HTM into other forms of data, say JSON? – Picture below (taken from browser elements of the htm) – Basically I just want to filter out html syntaxes and just retrieve the data.

enter image description here


Solution: use RegEx to filter HTML syntaxes.

Similar post:
Regular expression to remove HTML tags from a string

This Question was asked in StackOverflow by Chiu and Answered by Chiu It is licensed under the terms of CC BY-SA 2.5. - CC BY-SA 3.0. - CC BY-SA 4.0.

people found this article helpful. What about you?