Calling Web (native) APIs from UI Builder?

Hi backendless Team.
You are doing a wonderful job with your product. The product is very comprehensive and business relevant.
My question is about your mobile web client strategy for the foreseeable future:
I’m trying to avoid building device dependent mobile apps for Android or iOS. Web containers (browsers) are already supporting a variety of (Javascript-)APIs wich are mobile relevant and which are abstracting from the device’s operating system but still interfacing with the respective native APIs. To name some: Take pictures via the camera, share files via native share dialogs, access the client file system, access contacts, register as a share-target for other apps on the device, badging, barcode detection, notifcations, and more … (see e.g. https://fugu-tracker.web.app/).

Can I link to such APIs if 'm building my web client with UI Builder? Today, I guess, the answer is no. Do I have to select another way of building my web clients? Is it reasonable to wait until you have at least enabled custom JavaScript breakouts in UI Builder?

I really like the whole story you are selling from client development to backend. Maybe you can give me some indication w.r.t. timelines to let me decide how I can proceed (or wait) on the web client side.

Thanks and regards,

1 Like

Hello @Klaas_Klever

Thank you for these kind words! We are really appreciate this!

My question is about your mobile web client strategy

We plan to create a native mobile wrapper for rendering a UI-Builder app inside as a WebView, and using some kind of bridge to get access to the native API (methods/events)

Can I link to such APIs if 'm building my web client with UI Builder? Today, I guess, the answer is no.

Yes, you’re right, at this moment there is no way to embed custom JS code

Do I have to select another way of building my web clients? Is it reasonable to wait until you have at least enabled custom JavaScript breakouts in UI Builder?

I just created a discussion ticket BKNDLSS-24331 to consider the ability to allow adding Custom JS Code, I believe it might be the fastest way to cover all the API you need.

Do you mind if I ask you a few questions:

  1. are you going to upload your app to the Apple/Google app stores? or you will host it as a WEB app (Progressive WEB App)?
  2. which feature (native API) would you like to see firstly in the Codeless?

Regards, Vlad

Hi @vladimir-upirov ,

  1. This is the main background of my questions. I want to deliver a Progressive Web App (PWA, https://web.dev/progressive-web-apps/), which does not necessarily requires interaction with an app store. For discovery and monetization, you can still have a lean Google Play Store wrapper around your PWA if you like. Still, the app is made with the regular web app programing model (html, css, js) and will run on all modern web containers on Desktop, Android and iOS. PWAs are installable (and offline capable), no matter whether you receive them via the app store or just via your mobile browser.

  2. I think, very common features of apps are:

This is of course just my personal selection.

If you would open up the option to attach JS-code to events, then the above APIs and others might be easily addressed.

Note, that the concept of PWA also requires, that the developer delives at least two files to the root directory of the web server. (1) a manifest-file (json format) which describes PWA properties (https://web.dev/add-manifest/) and (2) the service worker JS implementation (Introduction to Service Worker  |  Web  |  Google Developers). As far as I know, delivering extra files is not possible today. The service worker controls the app lifecycle and more, for instance, offline capabilities. A service worker is a type of web worker, which runs in a thread separate from the main browser thread. Therefore, it cannot directly intefere with the DOM.

Note that one more (simple) feature will be required to support PWAs. The manifest location must be declared in each HTML page via <link rel="manifest" href="/manifest.json">. As far as I know, this is not possible today with UI Builder to enhance on the html-level.

Hope this helps,
best regards,

Thanks a lot for such detailed response and all the information. We will take this into consideration for sure.