Mobile + Web Client

Hi everyone

I’m new to meteor (6 days) i really love the framework but one thing i’m a bit confused about is how to structure an app where i’ll have two types of client interfaces web and mobile . Somewhere i saw where i might need two separate projects :cry:
Mobile :- Ionic
Web :- semantic or bootstrap or anything else i like :stuck_out_tongue:

Also the answer should be able to help decide if i should rebuild the company’s apps (Firebase + Other services)

You have one build which can be deployed across platforms.

Once you complete your build in JavaScript on the platform, you can deploy using frameworks like phone gap and other on either web and/or mobile.

Hope this helps!

OK thanks what about the hot push/reload part ?

That comes for free regardless of your target platform. This page goes into a lot of detail regarding this.

So does anyone have a recommended structure or should i just create two separate apps and connect them using the ddp

To my knowledge, I don’t see how you can have both in the same project because Meteor is going to pull all the HTML/JS under the client directory to build your UI. Plus you’re going to have different packages that you’ll want to use for Ionic and others for the Web App. To that end, you need two projects.

Of course if Ionic isn’t a hard requirement, you could just build a responsive app with bootstrap and have both clients use it.

Nice sounds like the way to go so which would you recommend the best way to share the same data and keep the realtime goodness

symbolic links
shared database
connect via ddp

I’d recommend researching this but a quick Google search led me to this: Good luck!

I did alot of research :slight_smile: but that one is new to me thanks looks interesting

Everything is good. You can connect through DDP, get data and call methods. But I’m now stacked on authentication. If I login in mobile app and refresh page I become logged out. And I didn’t find the solution yet.

1 Like

You can try something like

meteor_runtime_config.ACCOUNTS_CONNECTION_URL = “the_url”;

1 Like

@triniwiz you are right. Solution is to add __meteor_runtime_config__.ACCOUNTS_CONNECTION_URL = "the_url";
somewhere in your app’s server-side code.

Well i solved my issue with creating multiple packages :smile:

1 Like

@triniwiz could you please give more details or maybe link to read about it?

@achirkof @triniwiz @occasl @emmaodia
Hi, guys…
I build a web service REST API from meteor
and the client is native android java. I wanna upload file from my
android using rest or ddp. but until now, i havent found the solution
about uploading file via ddp or using rest. Anybody wants to help me?

@isdzulqor check this repo. maybe it helps.