This is a simple web scraper built using Node.js, Express, Cheerio, and Axios. It fetches the latest articles from the BBC website (https://www.bbc.com/) and prints an array of objects called "articles" to the console. Each object contains the headline and the link to the article.
- Node.js installed on your machine
-
Clone the repository or download the source code.
-
Open a terminal and navigate to the project directory.
-
Install the dependencies by running the following command:
npm install
-
Open a terminal and navigate to the project directory.
-
Run the following command to start the scraper:
npm run start
-
Once the scraper starts, it will fetch the latest articles from the BBC website and print the array of objects to the console.
- Node.js - A JavaScript runtime environment.
- Express - A web application framework for Node.js.
- Cheerio - A fast, flexible, and lean implementation of jQuery for server-side scraping.
- Axios - A promise-based HTTP client for Node.js.
This project is licensed under the MIT License.