This is a simple Angular 10 application for displaying latest news, by calling news API provided by https://newsapi.org/.
Register at https://newsapi.org/ and obtain an API key for running the application. API key is not given in this source code.
Do not use this code in production, without having a proxy of your own and having additional authentication, as your your API key can easily be retrieved by anyone from the browser.
- Get your API from https://newsapi.org/
- Update environment variable
apiKey: '<get_your_own_key>'
inenvironment.ts
file - run
npm update
- run
ng serve -o
to view the latest news served by the API. - Or run it with docker
docker build . -t news-reader-app
docker run -d -p 80:80 --rm --name news-site news-reader-app
- Large screen rendering
- Small screen rendering and navigation