{"id":16775057,"url":"https://github.com/tomer8007/wikipedia-to-json","last_synced_at":"2025-04-10T20:07:30.200Z","repository":{"id":86522921,"uuid":"96619797","full_name":"tomer8007/wikipedia-to-json","owner":"tomer8007","description":"Node.js module for parsing the content of wikipedia articles into javascript objects ","archived":false,"fork":false,"pushed_at":"2021-10-24T16:30:35.000Z","size":8,"stargazers_count":9,"open_issues_count":0,"forks_count":2,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-03-24T17:52:41.182Z","etag":null,"topics":["javascript","json","nodejs","parser","wikipedia","wikipedia-dump"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/tomer8007.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":"2017-07-08T13:11:15.000Z","updated_at":"2024-02-23T19:57:52.000Z","dependencies_parsed_at":null,"dependency_job_id":"d58d8519-08fb-4916-afc2-667d04385d88","html_url":"https://github.com/tomer8007/wikipedia-to-json","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tomer8007%2Fwikipedia-to-json","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tomer8007%2Fwikipedia-to-json/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tomer8007%2Fwikipedia-to-json/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tomer8007%2Fwikipedia-to-json/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tomer8007","download_url":"https://codeload.github.com/tomer8007/wikipedia-to-json/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248288346,"owners_count":21078903,"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":["javascript","json","nodejs","parser","wikipedia","wikipedia-dump"],"created_at":"2024-10-13T06:50:53.559Z","updated_at":"2025-04-10T20:07:30.176Z","avatar_url":"https://github.com/tomer8007.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Wikipedia to JSON\nUse this library to parse the HTML of wikipedia articles into machine-readable JSON objects. \nFor example:\n```javascript\n[ \n  { type: 'MAIN_TITLE', text: 'United States' },\n  { type: 'MAIN_IMAGE_URL',\n    url: 'https://upload.wikimedia.org/wikipedia/en/thumb/a/a4/Flag_of_the_United_States.svg/500px-Flag_of_the_United_States.svg.png',\n    full_url: 'https://upload.wikimedia.org/wikipedia/en/a/a4/Flag_of_the_United_States.svg' },\n  { type: 'TITLE', text: 'Introduction' },\n  { type: 'PARAGRAPH',\n    text: 'The United States of America (/əˈmɛrɪkə/; USA), commonly known as the United States  ...' },\n  { type: 'PARAGRAPH',\n    text: 'At 3.8 million square miles ...' },\n  ...\n  { type: 'TITLE', text: 'Etymology' },\n  { type: 'IMAGE',\n    url: 'https://upload.wikimedia.org/wikipedia/commons/thumb/9/9a/Amerigo_Vespucci_-_Project_Gutenberg_etext_19997.jpg/140px-Amerigo_Vespucci_-_Project_Gutenberg_etext_19997.jpg',\n    width: 140,\n    height: 169,\n    caption: 'America is named after Italian explorer Amerigo Vespucci.[45][46]',\n    side: 'LEFT' },\n  ...\n  { type: 'SUBTITLE', text: 'Indigenous and European contact' },\n  ...\n]\n```\n## Installation and dependencies\nFirst, install the dependencies with node package manager (npm):\n```\nnpm install request\nnpm install jsdom\n```\nAnd then just clone it:\n```\ngit clone https://github.com/tomer8007/wikipedia-to-json\n```\n## Usage\n```javascript\nvar wikipediaParser = require('./WikipediaParser');\nwikipediaParser.fetchArticleElements(\"United States\").then(function(result)\n{\n   console.log(result);\n   \n}).catch(function(error)\n{\n  console.log(error);\n});\n```\n## Currenty Supported Elements\n- Titles\n- Paragraphs\n- Subtitles\n- Images\n- Lists\n- Quotes\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftomer8007%2Fwikipedia-to-json","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftomer8007%2Fwikipedia-to-json","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftomer8007%2Fwikipedia-to-json/lists"}