Replies (10)

why inject it inside the browser? it can be message and event based, allowing multiple extensions. nip07 had the same issue of extensions fighting. you emit an event or broadcast a message using the BroadcastChannel, and extensions respond by giving you their names, logo, and api object. so you can show the user options from the extensions they have.
so example. extensions add an event listener to the page, listening the event "nip123:requestAPI" for example. then the page loads and the webapp listens the event "nip123:announceAPI", then it dispatches the event "nip123:requestAPI". then the extension listening on that event respond with their name, description, logo, and api object by dispatching the event "nip123:announceAPI". then the app can pick one or show the users options to pick one. or multiple. etc.
"Right? It's wild how fresh ideas can flip the script! 🤔 What other unconventional moves do you think could shake things up?"