jp pfp
jp
@jpfraneto.eth
idea: allow us to link casts on mini app notifications. and the end of day, our role as developers is to craft experiences that add value to the life of users, and on the case of the notification of this screenshot that notification if tapped could perfectly open a cast, inside the farcaster interface, and the miniapp open below. but not fullscreen. minimized on the place I decide the user to propose that user a precise interaction, based on the screen i know they are seeing
2 replies
1 recast
13 reactions

0xSpencer.base.eth pfp
0xSpencer.base.eth
@0xspencer
My way around this is a ‘/cast/:hash’ route in my miniapp that auto calls the view cast action of the sdk
2 replies
0 recast
1 reaction

jp pfp
jp
@jpfraneto.eth
oh sick. can you share a screenshot of the code and also a screen recording of the UX?
1 reply
0 recast
0 reaction

0xSpencer.base.eth pfp
0xSpencer.base.eth
@0xspencer
Here’s the ux, short window of opening the frame is unfortunately unavoidable. I can get you a gist of the code in the morning, but it’s just exposing a new route with the cast hash as a parameter, then calling sdk.actions.viewCast(hash), then rerouting the user to the desired miniapp page (which they won’t see bc the app instantly minimizes when viewing the cast)
1 reply
0 recast
1 reaction

jp pfp
jp
@jpfraneto.eth
very cool. this is exactly what i meant. on the case of the $runner miniapp it makes all the sense of the world also. each run is a cast. i want to see that cast. and interact with it. i will implement it right away when you show me the code. thank you. hope you don't forget or neither i
1 reply
0 recast
1 reaction

0xSpencer.base.eth pfp
0xSpencer.base.eth
@0xspencer
gotchu 🫡 https://gist.github.com/gtspencer/e869685e77bf3cae50a34abf8a35661c this is broken up into 3 parts: - backend notification sender - CastRoute.tsx that handles parsing of the url, opening of the cast, and redirecting - App.tsx where the cast route is created let me know if this makes sense; happy to hop on a call and chat through it if needed! Also happy to add this to the $runner miniapp myself if you want to add me as a contributor!
1 reply
1 recast
2 reactions

jp pfp
jp
@jpfraneto.eth
clear as water. i just implemented it and am shipping to prod to test 👀 next run that someone shares as a cast we will see if it worked
0 reply
0 recast
1 reaction