How to Create an Android Project
This guide walks you through creating a new Android project for Bagisto Native.
Step 1: Clone the Repository
Clone the Bagisto Native Android repository:
bash
git clone https://github.com/SocialMobikul/BagistoNative_Android.git
cd BagistoNative_AndroidStep 2: Open in Android Studio
- Open Android Studio.
- Select Open an existing project.
- Navigate to the
BagistoNative_Androidfolder. - Click OK.
Step 3: Wait for Gradle Sync
Android Studio will automatically:
- Download required dependencies
- Set up the project structure
- Index files for code completion
This may take a few minutes on first run.
Step 4: Configure Project
Edit app/build.gradle.kts to configure your app:
kotlin
android {
namespace = "com.example.yourapp"
defaultConfig {
applicationId = "com.example.yourapp"
versionCode = 1
versionName = "1.0.0"
}
}Step 5: Set Base URL
In MainActivity.kt, set your storefront URL:
kotlin
override fun navigatorConfigurations() = listOf(
NavigatorConfiguration(
name = "main",
startLocation = "https://your-storefront.com"
)
)Step 6: Run the Project
- Click the Run button (green arrow) in the toolbar.
- Select an emulator or connected device.
- Your app will launch with your web content.
Next Steps
- Install Android Studio - Set up development environment
- Add Gradle Dependency - Add the library to your project
- Build Release APK - Prepare for Play Store
