I see your intentions here, it makes sense to want to integrate a webview of a Discourse forum in an existing app. I’ve seen this done in a few apps and if you have experienced mobile app developers it’s not an impossible task.
Your challenges will be around:
authentication, some identity providers (e.g. Google), do not allow authentication in a webview, period. And it’s tricky to sync sessions between your native app and the webview
push notifications: you need to hook up your Discourse notifications to an APNS server somewhere, you can do this via web hooks, a custom Discourse plugin or a third party (OneSignal, Amazon SNS, etc.)
And as Sam noted above, there will be little details and maintenance issues that will creep up over time.
Thank you so much @pmusaraj That is extremely helpful. I agree that the authentication and notifications seem to be the biggest challenges - but I’m going to go for it! I will keep folks posted. It makes sense that Discourse as a whole wants to be cautious with this, because a company requires dev resources and it is not “out of the box”. But I think in my case I can get it done!
If you do wind up working on this, I think it’ll help a lot to make this an open-source library, so that other devs can help share the load of maintenance.
Correct, note that @James_Cribbs wants to include Discourse in an existing app, so neither the DiscourseHub repo nor the white label repo are useful in his scenario.
@pmusaraj still could be useful for methods/techniques on the push notifications (OneSignal?). I’m planning to do it in phases, getting authentication working first then doing notifications as a phase 2.
I put the project on pause for business reasons, not related to the implementation. My developer basically had it working but I offered a subscription service that could be purchased off-app and unlock content in the app - which Apple didn’t like! So project on pause but I think should be feasible
Oh, that’s a bummer. I am looking to integrate it on my company’s app also and I was just wondering which design approach to take. Can you point me towards any pointers that may prove helpful?
Hi,
I’m also following up here. Have you ever continued? Or is there any example of a successful implementation?
We also want to build our community in-app but after reading this thread I’m sad to hear that it’s not possible to do this with Discourse. Would love to know if some people made it.
I didn’t complete this yet, but I’m currently looking at reviving my community. I found a community called BetterMode that supports embedding in apps, but I don’t think it’s really any different from what you can do with Discourse. I also love how snappy Discourse is. Might be reviving this project soon!
Hi @James_Cribbs and others! I am planning to build a wellness community platform to be as accessible and open-source as possible likely using React.js & Native React.
The community features of Discourse are incredible, but forcing app users to switch from native app to web app (or to download a second app) due to auth issues or for notifications is a hard pill to swallow.
I looked into Bettermode/Tribe, which has an amazing feature set. I am not sure I want to outsource a core value prop to a single source of failure for +$7,188 a year, but I am tempted. Migrating off of Bettermode down the road looks like it could be quite challenging.
Please keep us posted if you do explore Discourse native app integration / embedding further! I might start developing around Discourse and offering a less interactive no auth webview but @sam ’s warnings are scaring me off.
Your comment on unlocking iOS app content by paying in web-only and Apple not playing along is also helpful context.
Any further thoughts / advice / issues you’ve run into would be helpful as I think through appropriate solutions.
I got rejected multiple times by Apple when trying to submit an app with a Discourse community. It seems to break their design guidelines. Has anyone managed to get around this issue?