Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

simonhamp's avatar

simonhamp wrote a comment+100 XP

2w ago

Thanks 😊

Mobile and Desktop's architectures are completely different. Plugins for Mobile don't work on Desktop

Desktop does support a kind of secure storage via Electron APIs for encrypting values via a key that is generated and stored in the user's keychain.

This is all abstracted away for you so you just need to use these System::encrypt() and System::decrypt() methods: https://nativephp.com/docs/desktop/2/the-basics/system#encryption-decryption

simonhamp's avatar

simonhamp wrote a comment+100 XP

2mos ago

@akaydin I'm not sure what you mean: "Is it practical to have common files for those two apps?"

how do they handle multi-platform and secure apps?

NativePHP is multi-platform by default - your single Laravel codebase is used to build binaries for each platform.

No apps distributed to a user's device are 100% secure. Any critical business logic should always run server-side with a secure API in front of it

simonhamp's avatar

simonhamp wrote a comment+100 XP

2mos ago

@Mike Swan you can try asking in our Discord

simonhamp's avatar

simonhamp wrote a comment+100 XP

2mos ago

@Prantho-das Please join the Discord for support

simonhamp's avatar

simonhamp liked a comment+100 XP

2mos ago

Incredibly, despite what Simon says in this video, NativePHP for Mobile is now free!

https://nativephp.com/blog/nativephp-for-mobile-is-now-free

However, at the same time, some of the native features (geolocation, biometrics, etc) have moved to plugins, which are NOT free. But the core native functionality is.

simonhamp's avatar

simonhamp wrote a comment+100 XP

2mos ago

@JohnRivs if you're not using native features, do you need a distributed application?

simonhamp's avatar

simonhamp wrote a comment+100 XP

2mos ago

@gwleuverink Exactly!

simonhamp's avatar

simonhamp liked a comment+100 XP

2mos ago

Another argument against coupling your server and client classes;

At any point in time you may have different app versions consuming your api. If your mobile/desktop app would share say the same models you’ll undoubtedly run into trouble down the line.

Keep that stuff separate and think in terms of api versions and backwards compatibility. Out of date apps will linger around. It is a different paradigm!

simonhamp's avatar

simonhamp liked a comment+100 XP

2mos ago

@Prantho-das hi there. You can't do it like you normally would with web application. Only SQLite is available for native apps, as Simon explained in the video, cause of the physical limitations, and connecting directly to MySQL database that is online is a huge security risk (as Simon explained in the video). What you can do though, is create a web app that's using MySQL, set up the API endpoints from your web app and benefit from MySQL that way. But you would still probably have to use SQLite for some data, cause you probably need to store at least some data on your device.

simonhamp's avatar

simonhamp liked a comment+100 XP

2mos ago

🤍🤍

simonhamp's avatar

simonhamp liked a comment+100 XP

2mos ago

 ❤️

simonhamp's avatar

simonhamp liked a comment+100 XP

2mos ago

Thanks this is Gonna be cool !

simonhamp's avatar

simonhamp liked a comment+100 XP

2mos ago

Nice 👌

simonhamp's avatar

simonhamp liked a comment+100 XP

2mos ago

2026 has started off with a bang on Laracasts with the quantity and quality of content!

I had a fear that AI might have discouraged content creation, but AI doesn't yet engage quite like an expert instructor. Keep up the good work!

simonhamp's avatar

simonhamp liked a comment+100 XP

2mos ago

woow

simonhamp's avatar

simonhamp liked a comment+100 XP

2mos ago

lets goooo🐦‍🔥🤍⚡