How christophergrossdev/stock-price-app works
This is a browser-based stock dashboard. A visitor searches for a ticker or selects an earnings card; the script then fetches and displays quote, daily candlestick, and news data, while the earnings view loads on startup and can switch between mock and API data. The single script owns these features and their DOM updates. The source excerpt does not show the HTML or styling, so UI connections are based only on the script’s referenced element IDs.
Main entry points: script.js Dashboard logic · index.html Dashboard UI
Components 12
Market data
- Quote lookup
script.js - Chart data
script.js - Candlestick chart
script.js - News feed
script.js
Earnings
- Earnings loader
script.js - CSV parser
script.js - Earnings list
script.js
Browser app
- Dashboard UI
index.html - Dashboard logic
script.js
Other components
- Visitor
- Alpha Vantage
- Chart.js
Connections 19
- Visitor → Dashboard UI: uses
- Dashboard UI → Dashboard logic: triggers
script.js - Dashboard logic → Quote lookup: requests
script.js - Dashboard logic → Chart data: requests
script.js - Dashboard logic → News feed: requests
script.js - Quote lookup → Alpha Vantage: fetches quote
script.js - Chart data → Alpha Vantage: fetches series
script.js - Chart data → Candlestick chart: passes data
script.js - Candlestick chart → Chart.js: renders with
script.js - News feed → Alpha Vantage: fetches news
script.js - Dashboard logic → Earnings loader: loads on startup
script.js - Dashboard logic → Earnings loader: reloads on toggle
script.js - Earnings loader → Alpha Vantage: fetches calendar
script.js - Earnings loader → CSV parser: parses response
script.js - Earnings loader → Earnings list: updates list
script.js - Earnings list → Dashboard logic: handles selection
script.js - Dashboard logic → Quote lookup: fetches selected quote
script.js - Dashboard logic → Chart data: fetches selected chart
script.js - Dashboard logic → News feed: fetches selected news
script.js