|
| 1 | +# AGENTS.md |
| 2 | + |
| 3 | +## Project Overview |
| 4 | +Argo is a fast, focused navigation launcher for the Arweave Permaweb. It provides intelligent autocomplete, filtered search modes, and quick launch capabilities for seamless navigation across Permaweb resources. |
| 5 | + |
| 6 | +Built with Vue 3, it focuses on dual functionality: **Discovery** (multi-select filters for finding content) and **Launch** (direct access to ArNS domains, transactions, and future hyperbeam hashpaths). |
| 7 | + |
| 8 | +**Current Features**: Multi-select filters, transaction shortcuts, ArNS resolution, undername support, automatic transaction detection. |
| 9 | +**Future Roadmap**: Launch/Find mode split, Hyperbeam integration for device calling via hashpaths. |
| 10 | + |
| 11 | +## Setup Commands |
| 12 | +- Install dependencies: `bun install` |
| 13 | +- Start dev server: `bun run dev` |
| 14 | +- Build for production: `bun run build` |
| 15 | +- Preview build: `bun run preview` |
| 16 | +- Deploy: `bun run deploy` (builds project, deployment handled by GitHub Actions) |
| 17 | + |
| 18 | +## Code Style |
| 19 | +- Vue 3 Composition API with `<script setup>` |
| 20 | +- JavaScript (ES6+), no TypeScript |
| 21 | +- Use existing composables and helpers from `/src/composables/` and `/src/helpers/` |
| 22 | +- Follow established component patterns in `/src/components/` |
| 23 | +- Consistent formatting, no semicolons |
| 24 | +- Prefer functional patterns where possible |
| 25 | + |
| 26 | +## Testing & Quality |
| 27 | +- Build verification: `bun run build` (ensure no build errors) |
| 28 | +- Test in browser after dev server starts |
| 29 | +- Check Vue DevTools for component issues |
| 30 | +- Verify ArNS resolution and AO integration functionality |
| 31 | +- Test mobile responsiveness |
| 32 | + |
| 33 | +## Project Structure |
| 34 | +``` |
| 35 | +src/ |
| 36 | +├── components/ # Vue components |
| 37 | +│ ├── ArweaveWalletConnection.vue |
| 38 | +│ ├── BangEditor.vue |
| 39 | +│ ├── Explorer.vue |
| 40 | +│ ├── HeadlessRedirect.vue |
| 41 | +│ ├── KeyboardShortcuts.vue |
| 42 | +│ ├── LoadingScreen.vue |
| 43 | +│ ├── ResultDisplay.vue |
| 44 | +│ ├── SearchBar.vue |
| 45 | +│ └── UrlForm.vue |
| 46 | +├── composables/ # Vue composables |
| 47 | +│ ├── useAppState.js |
| 48 | +│ ├── useBangs.js |
| 49 | +│ ├── useKeyboardShortcuts.js |
| 50 | +│ ├── useSearch.js |
| 51 | +│ └── useWallet.js |
| 52 | +├── helpers/ # Utility functions |
| 53 | +│ ├── arnsResolver.js |
| 54 | +│ ├── arweaveWallet.js |
| 55 | +│ ├── bangHelpers.js |
| 56 | +│ ├── cacheModule.js |
| 57 | +│ ├── searchLogic.js |
| 58 | +│ └── walletManager.js |
| 59 | +├── assets/ # Static assets |
| 60 | +├── App.vue # Main app component |
| 61 | +├── main.js # App entry point |
| 62 | +├── polyfills.js # Browser polyfills |
| 63 | +└── store.js # State management |
| 64 | +``` |
| 65 | + |
| 66 | +## Key Dependencies |
| 67 | +- **Vue 3** - Frontend framework |
| 68 | +- **@ar.io/sdk** - ArNS resolution and AR.IO integration |
| 69 | +- **@permaweb/aoconnect** - AO process integration |
| 70 | +- **lodash** - Utility functions |
| 71 | +- **Vite** - Build tool and dev server |
| 72 | + |
| 73 | +## Core Features to Maintain |
| 74 | + |
| 75 | +### Discovery Features |
| 76 | +- Multi-select filters (All, ArNS, Docs, Glossary) |
| 77 | +- ArNS domain resolution with autocomplete (10,000+ domains) |
| 78 | +- Undername support (mobile inline, desktop side panel) |
| 79 | +- Real-time content filtering and suggestions |
| 80 | + |
| 81 | +### Launch Features |
| 82 | +- Transaction shortcuts (tx, data, raw, msg) |
| 83 | +- Automatic transaction ID detection |
| 84 | +- Direct ArNS navigation |
| 85 | +- Headless mode support |
| 86 | + |
| 87 | +### User Experience |
| 88 | +- Dark mode toggle |
| 89 | +- Keyboard navigation |
| 90 | +- Mobile-first responsive design |
| 91 | + |
| 92 | +### Future Features (Coming Soon) |
| 93 | +- Launch/Find mode split for focused workflows |
| 94 | +- Hyperbeam integration for hashpath creation and device calling |
| 95 | + |
| 96 | +## Development Guidelines |
| 97 | +- Use existing composables for state management |
| 98 | +- Follow established patterns in components |
| 99 | +- Maintain mobile-first responsive design |
| 100 | +- Test ArNS resolution functionality |
| 101 | +- Verify AO integration works correctly |
| 102 | +- Check keyboard shortcuts functionality |
| 103 | +- Ensure dark mode compatibility |
| 104 | +- Focus on discovery and launch workflows |
| 105 | +- Prepare for future launch/find mode separation |
| 106 | + |
| 107 | +## Security Considerations |
| 108 | +- Never commit wallet files or private keys |
| 109 | +- Use environment variables for sensitive data |
| 110 | +- Follow Arweave security best practices |
| 111 | +- Validate user inputs for ArNS names and transaction IDs |
| 112 | + |
| 113 | +## Deployment |
| 114 | +- GitHub Actions handle automatic deployment |
| 115 | +- Two workflows: `deploy-arweave.yml` and `deploy-vercel.yml` |
| 116 | +- Uses permaweb-deploy for Arweave deployment |
| 117 | +- No manual deployment required |
| 118 | +- Build artifacts go to `/dist` directory |
| 119 | + |
| 120 | +## Common Tasks |
| 121 | +- Modifying search logic: Update `useSearch.js` and `searchLogic.js` |
| 122 | +- Adding new filters: Update filter components and search logic |
| 123 | +- ArNS resolution improvements: Update `arnsResolver.js` |
| 124 | +- Transaction handling: Modify transaction detection and shortcut logic |
| 125 | +- Styling changes: Modify `/src/assets/styles.css` |
| 126 | +- Component updates: Follow existing component patterns |
| 127 | +- Preparing for launch/find mode: Plan component separation for future updates |
| 128 | + |
| 129 | +## Legacy Components (Being Phased Out) |
| 130 | +- Bang-related functionality (`useBangs.js`, `bangHelpers.js`, `BangEditor.vue`) - Do not extend or enhance |
| 131 | +- Focus development on filter-based discovery and direct launch capabilities |
| 132 | + |
| 133 | +## File Patterns to Avoid |
| 134 | +- Do not add Lua files (project uses JavaScript/Vue only) |
| 135 | +- Do not commit wallet files or private keys |
| 136 | +- Avoid adding unrelated project files |
| 137 | +- Follow existing .gitignore patterns |
| 138 | +- Do not create new bang-related features (focus on filters and launch capabilities) |
0 commit comments