Imported from axiomshuvo/readora (
AGENTS.md). Install upstream withnpx skills add axiomshuvo/readora. Copyright stays with the author.
This is NOT the Next.js you know
This version has breaking changes — APIs, conventions, and file structure may all differ from your training data. Read the relevant guide in node_modules/next/dist/docs/ before writing any Next.js-specific code. Heed deprecation notices.
Always verify library versions before writing any code
⛔ NEVER write any library-specific code without first reading package.json AND the relevant node_modules/<pkg>/dist/*.d.ts. Violation of this rule causes bugs.
Before using any library API, component, or prop — read package.json first.
Current dependency versions (from package.json)
| Package | Version |
|---|---|
next |
16.2.6 |
react / react-dom |
19.2.4 |
@heroui/react |
^3.0.5 |
@heroui/styles |
^3.0.5 |
better-auth |
^1.6.11 |
swiper |
^12.1.4 |
react-icons |
^5.6.0 |
react-fast-marquee |
^1.6.5 |
react-hot-toast |
^2.6.0 |
tailwindcss |
^4 |
mongodb |
^7.2.0 |
Rules
Version Checks (do these first)
- Read
package.jsonbefore using any library API to confirm the installed major version. - Read
node_modules/<package>/dist/*.d.tsto confirm a specific prop or component exists before using it.
API Usage
- Never assume an API from training data. Major versions often have breaking changes. A prop or component that existed in v2 may not exist in v3.
- HeroUI v3 is NOT HeroUI v2 / NextUI. It is built on React Aria. Key differences discovered in this project:
Inputdoes NOT supportstartContent,endContent,classNames, orvariant="bordered". UseInputGroupwithInputGroup.Prefix/InputGroup.Suffixinstead.Buttondoes NOT supportstartContent. Place icons as direct children. UseisPendingnotisLoading. Valid variants:primary | secondary | tertiary | outline | ghost | danger.Fieldset.Grouphas built-in CSS (w-full space-y-4) that conflicts with custom grid classes — use a plain<div>for grid layouts insideFieldset.Checkboxrequires full compound anatomy:Checkbox.Control → Checkbox.Indicator+Checkbox.Content → Label.toast()fromreact-hot-toasttakes a string or JSX — NOT an object{title, description}.
- Swiper v12 has a different API than v9/v10. Check
node_modules/swiper/before using any Swiper props or modules.
Auth & Async
callbackURLin better-auth only applies to email verification flows — it does not auto-redirect after sign-in/sign-up. Userouter.push()manually after a successful auth call.- Never use
setTimeoutas a substitute for real async handling. Alwaysawaitthe actual call and set loading state from its result.