Install Vercel Speed Insights with docs - #3
Open
vercel[bot] wants to merge 1 commit into
Open
vercel[bot] wants to merge 1 commit into
vercel[bot] wants to merge 1 commit into
Conversation
## Vercel Speed Insights Installation
Successfully installed and configured Vercel Speed Insights for the ZenkaiTV anime streaming application.
### Changes Made
**1. Package Installation**
- Added `@vercel/speed-insights` v2.0.0 as a dependency
- Updated `package.json` and `package-lock.json` with the new package
**2. Integration into HTML Files**
Modified both HTML entry points to include the Speed Insights initialization:
- `index.html` - Main web application entry point
- `android/app/src/main/assets/index.html` - Android TV app entry point
Added the following script before the closing `</head>` tag in both files:
```html
<!-- Vercel Speed Insights -->
<script type="module">
import { injectSpeedInsights } from './node_modules/@vercel/speed-insights/dist/index.mjs';
injectSpeedInsights();
</script>
```
### Implementation Details
**Framework Detection:**
This project uses vanilla JavaScript/HTML (not a framework like Next.js or React), so I followed the Vercel documentation's HTML/Astro approach using the `injectSpeedInsights()` function.
**Why This Approach:**
- The project is a static HTML application with vanilla JavaScript
- Used ES module import to load the Speed Insights library
- The `injectSpeedInsights()` function automatically handles script injection and initialization
- This approach is compatible with the project's existing architecture
**Files Updated:**
1. `package.json` - Added @vercel/speed-insights dependency
2. `package-lock.json` - Updated with new package and its dependencies
3. `index.html` - Added Speed Insights script
4. `android/app/src/main/assets/index.html` - Added Speed Insights script (to maintain mirror sync)
### Verification
✅ All checks passed:
- `npm run check` - All syntax checks passed
- `npm test` - All 16 tests passed
- `npm run vercel-build` - Build completed successfully
- Asset version consistency verified
- Android mirror sync verified
- No global collisions detected
- Security audit passed
### Next Steps
After deployment to Vercel:
1. The Speed Insights script will automatically start collecting performance metrics
2. Data will appear in the Vercel dashboard under the Speed Insights section
3. Metrics typically begin showing within a few days after users visit the site
4. You can configure sampling rates and access advanced features in the Vercel dashboard
The integration is now complete and ready for deployment!
Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
Contributor
Author
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
JSolanoDev
added a commit
that referenced
this pull request
Sep 7, 2026
AniList is gone. It answers 403 from Vercel, from the browser, from a dev
machine and - proven by run #111, which finished the bake in 3 seconds - from
the GitHub Actions runner as well. The premise the bake was written on, that
Actions is a different network, was wrong, so the chains needed another source.
Jikan labels its relations "Prequel"/"Sequel", which is the same semantics
AniList gave us. The manami offline database supplies each entry's title,
episode count, year and AniList id, so a chain costs one Jikan request per
node rather than one per node per field.
The offline database's own relatedAnime is UNTYPED and is never the relation
source. Measured over this catalogue, untyped components merge 78 Gundam
series into a single "franchise", attach Ponkotsu Quest to Vinland Saga and
SKET Dance to Gintama. A test wires a real TV show in through Spin-off, Side
story and Other and asserts it never becomes a season.
Two things that had to be got right:
- Seeding only the rows we carry closes the component over fetched nodes and
leaves everything else a leaf. Mushoku Tensei season 1 is reachable only
through Part 2, which we do not carry, so the first version produced a chain
that began at Part 2 and silently dropped season 1 - the exact season being
asked for. The walk now follows the chain outward.
- /anime/{id}/relations answers 504 while /anime/{id}/full, carrying the same
typed relations, answers 200. Measured across all five Mushoku ids.
Opening Mushoku Tensei III now yields the whole franchise in release order:
#1 108465 Mushoku Tensei 11ep 2021 WINTER
#2 127720 Mushoku Tensei Part 2 12ep 2021 FALL
#3 146065 Mushoku Tensei II 12ep 2023 SUMMER
#4 166873 Mushoku Tensei II Part 2 12ep 2024 SPRING
#5 178789 Mushoku Tensei III 14ep 2026 SUMMER
Only #3 and #5 are in our catalogue; the rest render as visible, locked
seasons rather than not existing. The chain is identical opened from any of
them.
Preselection keeps the crawl honest: only rows sitting beside another TV/ONA
entry are worth asking about, 599 of 1071 here. Capped at 1400 requests paced
at 1.1s, and what the cap drops is logged rather than passed off as complete.
Workflow timeout raised to 40 minutes to match.
311 assertions green.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
JSolanoDev
added a commit
that referenced
this pull request
Sep 7, 2026
187 typed relation edges, 134 rows with a season chain. The three Mushoku Tensei links that answered 504 across four consecutive rounds earlier tonight answered on a later pass, which is exactly what the cache exists to capture: #1 2021 Mushoku Tensei 11ep #2 2021 Mushoku Tensei Part 2 12ep #3 2023 Mushoku Tensei II 12ep #4 2024 Mushoku Tensei II Part 2 12ep #5 2026 Mushoku Tensei III 14ep Only #3 and #5 are in our catalogue; the rest render as visible, locked seasons rather than not existing at all. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
JSolanoDev
marked this pull request as ready for review
September 19, 2026 03:18
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Vercel Speed Insights Installation
Successfully installed and configured Vercel Speed Insights for the ZenkaiTV anime streaming application.
Changes Made
1. Package Installation
@vercel/speed-insightsv2.0.0 as a dependencypackage.jsonandpackage-lock.jsonwith the new package2. Integration into HTML Files
Modified both HTML entry points to include the Speed Insights initialization:
index.html- Main web application entry pointandroid/app/src/main/assets/index.html- Android TV app entry pointAdded the following script before the closing
</head>tag in both files:Implementation Details
Framework Detection:
This project uses vanilla JavaScript/HTML (not a framework like Next.js or React), so I followed the Vercel documentation's HTML/Astro approach using the
injectSpeedInsights()function.Why This Approach:
injectSpeedInsights()function automatically handles script injection and initializationFiles Updated:
package.json- Added @vercel/speed-insights dependencypackage-lock.json- Updated with new package and its dependenciesindex.html- Added Speed Insights scriptandroid/app/src/main/assets/index.html- Added Speed Insights script (to maintain mirror sync)Verification
✅ All checks passed:
npm run check- All syntax checks passednpm test- All 16 tests passednpm run vercel-build- Build completed successfullyNext Steps
After deployment to Vercel:
The integration is now complete and ready for deployment!
View Project · Speed Insights
Created by juankisantiago-5844 with Vercel Agent