{"id":15099147,"url":"https://github.com/samuelcaldas/simplehtmlparser","last_synced_at":"2026-02-07T14:33:04.477Z","repository":{"id":245157782,"uuid":"817434559","full_name":"samuelcaldas/SimpleHtmlParser","owner":"samuelcaldas","description":"Simple HTML Parser is a lightweight Python library designed to extract content from HTML elements based on their ID or class attributes.","archived":false,"fork":false,"pushed_at":"2024-06-19T17:55:28.000Z","size":6,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-27T16:20:04.950Z","etag":null,"topics":["curl","html","html-class","html-id","parser","python","regex"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/samuelcaldas.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-06-19T17:43:27.000Z","updated_at":"2024-12-30T22:29:53.000Z","dependencies_parsed_at":"2024-06-20T06:12:03.166Z","dependency_job_id":"e3745ef5-405e-4dfa-b7be-c96c27ead6cf","html_url":"https://github.com/samuelcaldas/SimpleHtmlParser","commit_stats":null,"previous_names":["samuelcaldas/simplehtmlparser"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/samuelcaldas%2FSimpleHtmlParser","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/samuelcaldas%2FSimpleHtmlParser/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/samuelcaldas%2FSimpleHtmlParser/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/samuelcaldas%2FSimpleHtmlParser/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/samuelcaldas","download_url":"https://codeload.github.com/samuelcaldas/SimpleHtmlParser/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245878929,"owners_count":20687297,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["curl","html","html-class","html-id","parser","python","regex"],"created_at":"2024-09-25T17:06:27.167Z","updated_at":"2026-02-07T14:33:04.449Z","avatar_url":"https://github.com/samuelcaldas.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Simple HTML Parser\n\nSimple HTML Parser is a lightweight Python library designed to extract content from HTML elements based on their ID or class attributes.\n\n## Features\n\n- Fetch inner content from HTML elements by ID or class.\n- Easy-to-use interface with clear error messages.\n- Unit tests included for reliability.\n\n## Installation (WIP)\n\nTo install Simple HTML Parser, simply run:\n\n```bash\npip install simple-html-parser\n```\n\n## Usage\n\nImport the `HtmlParser` class and initialize it with the URL of the HTML page you want to parse:\n\n```python\nfrom html_parser import HtmlParser\n\n# Initialize HtmlParser with URL\nparser = HtmlParser('http://example.com')\n```\n\nTo extract content by ID:\n\n```python\ncontent_by_id = parser.with_id('example-id').get_inner_content()\nprint(f'Content by ID: {content_by_id}')\n```\n\nTo extract content by class:\n\n```python\ncontent_by_class = parser.with_class('example-class').get_inner_content()\nprint(f'Content by Class: {content_by_class}')\n```\n\n## Testing\n\nTo run the unit tests, execute:\n\n```bash\npython -m unittest test_html_parser.py\n```\n\n## Contributions\n\nContributions are welcome! Please submit a pull request or open an issue if you have any suggestions or improvements.\n\n## License\n\nSimple HTML Parser is released under the MIT License. See the [LICENSE](LICENSE) file for more details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsamuelcaldas%2Fsimplehtmlparser","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsamuelcaldas%2Fsimplehtmlparser","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsamuelcaldas%2Fsimplehtmlparser/lists"}