b-souty / html2dict Goto Github PK
View Code? Open in Web Editor NEWHtml2Dict allows you to retrieve all the tables present in a webpage or any html string you pass it.
Home Page: https://github.com/B-Souty/html2dict
License: MIT License
Html2Dict allows you to retrieve all the tables present in a webpage or any html string you pass it.
Home Page: https://github.com/B-Souty/html2dict
License: MIT License
I will add docstrings to the current code in order to improve maintainability. Going forward, any new function should have a docstring to start with.
edit: Can someone please review my PR #3
Currently the returned table are stored in a dictionary where each key is "table_n" where n is the number of the table on the page (i.e. {'table_0': [], 'table_1': [], ...}
)
If the caption tag is present in the table, the caption text should be used instead of "table_n".
While writing the docstrings, I realised it was a nightmare to describe the structure of a dictionary representing a table.
It might be easier to create a 'Table' class with an attribute for each type of table (raw html table, basic text table, rich formatted table, ...) . Or maybe even subclasses for each type. I'm not sure at this point.
I am open to suggestion.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.