Learn what Felgo offers to help your business succeed. Start your free evaluation today! Felgo for Your Business

Felgo Live Code Reloading: Web Editor

Run this example on your Android and iOS phone now, with the Felgo Live Scripting mobile app!

import QtQuick 2.0 import VPlayApps 1.0 import VPlayPlugins 1.0 App { NavigationStack { Page { title: "Firebase Storage" FirebaseStorage { id: storage config: FirebaseConfig { id: customConfig projectId: "v-play-live-client-test-db" databaseUrl: "https://v-play-live-client-test-db.firebaseio.com" storageBucket: "v-play-live-client-test-db.appspot.com" //platform dependent - get these values from the google-services.json / GoogleService-info.plist apiKey: Qt.platform.os === "android" ? "AIzaSyD3Pmw89NHhdG9nGIQWwaOB55FuWjcDSS8" : "AIzaSyCheT6ZNFI4mUwfrPRB098a08dVzlhZNME" applicationId: Qt.platform.os === "android" ? "1:40083798422:android:ed7cffdd1548a7fa" : "1:40083798422:ios:ed7cffdd1548a7fa" } } AppFlickable { anchors.fill: parent Column { width: parent.width anchors.margins: dp(12) AppButton { text: "Capture image + upload" onClicked: nativeUtils.displayCameraPicker() } AppText { id: status text: "Idle" } // this will display the image after it's uploaded AppImage { id: img width: parent.width fillMode: AppImage.PreserveAspectFit autoTransform: true } } } } } Connections { target: nativeUtils onCameraPickerFinished: { if(accepted) { //picture taken with camera is stored at path - upload to Firebase Storage storage.uploadFile(path, "test-image.png", function(progress, finished, success, downloadUrl) { if(!finished) { status.text = "Uploading... " + progress.toFixed(2) + "%" } else if(success) { img.source = downloadUrl status.text = "Upload completed." } else { status.text = "Upload failed." } }) } } } }

1. Download Felgo Live Scripting app

2. Open the app and add the displayed Dev ID here.

QML Hot Reload on all Platforms

With Felgo Live, you can reload code changes in real-time on any connected device. While this web editor is just for demonstration purposes, you can use hot reloading also for development on your desktop.

Download the Felgo Developer App app to run your code on Android and iOS, from Windows, macOS or Linux.

Qt_Technology_Partner_RGB_475 Qt_Service_Partner_RGB_475_padded