add localtunnel info

This commit is contained in:
lucas-neynar 2025-03-14 14:32:29 -07:00
parent 85671208dd
commit 8146693122
No known key found for this signature in database
3 changed files with 22 additions and 4 deletions

View File

@ -250,12 +250,9 @@ async function init() {
"class-variance-authority": "^0.7.1", "class-variance-authority": "^0.7.1",
"clsx": "^2.1.1", "clsx": "^2.1.1",
"dotenv": "^16.4.7", "dotenv": "^16.4.7",
"inquirer": "^12.4.3",
"localtunnel": "^2.0.2",
"lucide-react": "^0.469.0", "lucide-react": "^0.469.0",
"next": "15.0.3", "next": "15.0.3",
"next-auth": "^4.24.11", "next-auth": "^4.24.11",
"ox": "^0.4.2",
"react": "^18", "react": "^18",
"react-dom": "^18", "react-dom": "^18",
"tailwind-merge": "^2.6.0", "tailwind-merge": "^2.6.0",
@ -270,6 +267,7 @@ async function init() {
"@types/react-dom": "^18", "@types/react-dom": "^18",
"eslint": "^8", "eslint": "^8",
"eslint-config-next": "15.0.3", "eslint-config-next": "15.0.3",
"localtunnel": "^2.0.2",
"postcss": "^8", "postcss": "^8",
"tailwindcss": "^3.4.1", "tailwindcss": "^3.4.1",
"typescript": "^5" "typescript": "^5"

20
dev.js
View File

@ -8,9 +8,29 @@ let isCleaningUp = false;
async function startDev() { async function startDev() {
// Start localtunnel and get URL // Start localtunnel and get URL
tunnel = await localtunnel({ port: 3000 }); tunnel = await localtunnel({ port: 3000 });
let ip;
try {
ip = await fetch('https://ipv4.icanhazip.com').then(res => res.text()).then(ip => ip.trim());
} catch (error) {
console.error('Error getting IP address:', error);
}
console.log(` console.log(`
🌐 Local tunnel URL: ${tunnel.url} 🌐 Local tunnel URL: ${tunnel.url}
💻 To test on desktop:
1. Open the localtunnel URL in your browser: ${tunnel.url}
2. Enter your IP address in the password field${ip ? `: ${ip}` : ''}
3. Click "Click to Submit" -- your frame should now load
4. Navigate to the Warpcast Frame Developer Tools: https://warpcast.com/~/developers/frames
5. Enter your frame URL: ${tunnel.url}
6. Click "Preview" to launch your frame within Warpcast
You will not be able to load your frame in Warpcast until
you submit your IP address in the localtunnel password field
📱 To test in Warpcast mobile app: 📱 To test in Warpcast mobile app:
1. Open Warpcast on your phone 1. Open Warpcast on your phone
2. Go to Settings > Developer > Frames 2. Go to Settings > Developer > Frames

View File

@ -1,6 +1,6 @@
{ {
"name": "frames-v2-demo", "name": "frames-v2-demo",
"version": "0.1.6", "version": "0.1.7",
"type": "module", "type": "module",
"files": [ "files": [
"bin/index.js" "bin/index.js"