MCPcopy Index your code
hub / github.com/aryanvichare/stocks

github.com/aryanvichare/stocks @main

Chat with this repo
repository ↗ · DeepWiki ↗ · + Follow
21 symbols 75 edges 18 files 0 documented · 0%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Stock Picker

Deploy with Vercel

Demo web app using Next.js, React Server Components, and Streaming "server-rendered" stock price data from Polygon.io API. Original inspiration from @rauchg's tweet - https://x.com/rauchg/status/1809389050568298625

This project uses the brand new shadcn/ui charts library - https://ui.shadcn.com/charts.

Screenshot 2024-07-06 at 3 23 43 AM

Screenshot 2024-07-06 at 3 24 26 AM

Features

  • Built with Next.js App Router, Typescript, TailwindCSS, and Shadcn/UI (and latest charting components)
  • Uses React Server Components and Streaming "server-rendered" stock price data from Polygon.io API

Getting Started

  1. Clone this repository to your local machine:

bash git clone https://github.com/aryanvichare/stocks.git

  1. Move to the cloned directory

bash cd stocks

  1. Install dependencies:

bash npm install

  1. Copy the .env.example to your .env.local

bash cp .env.example .env.local

  1. Get your API Key from Polygon.io and paste it into your .env.local

  2. Run the development server:

bash npm run dev

Extension points exported contracts — how you extend this code

InteractiveStockChartProps (Interface)
(no doc)
components/InteractiveStockChart.tsx
ButtonProps (Interface)
(no doc)
components/ui/button.tsx
StockData (Interface)
(no doc)
lib/get-stock-data.ts
Company (Interface)
(no doc)
lib/stock-data.ts

Core symbols most depended-on inside this repo

cn
called by 34
lib/utils.ts
getPayloadConfigFromPayload
called by 3
components/ui/chart.tsx
useChart
called by 2
components/ui/chart.tsx
formatDate
called by 2
lib/get-stock-data.ts
getAugmentedFetchUrl
called by 1
lib/get-stock-data.ts
getEndpoint
called by 1
lib/get-stock-data.ts
getStockData
called by 1
lib/get-stock-data.ts
StockSelector
called by 0
components/StockSelector.tsx

Shape

Function 17
Interface 4

Languages

TypeScript100%

Modules by API surface

lib/get-stock-data.ts5 symbols
components/ui/chart.tsx3 symbols
components/StockSelector.tsx2 symbols
components/InteractiveStockChart.tsx2 symbols
lib/utils.ts1 symbols
lib/stock-data.ts1 symbols
components/ui/dropdown-menu.tsx1 symbols
components/ui/button.tsx1 symbols
components/theme-toggle.tsx1 symbols
components/theme-provider.tsx1 symbols
components/icons/GithubIcon.tsx1 symbols
app/page.tsx1 symbols

For agents

$ claude mcp add stocks \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact