Building Portfolio Website with Compose Multiplatform (1)

Andrea
3 min readOct 30, 2024

--

Hello 👋. Today I am going to create and documented building application for my portfolio using Compose Multiplatform. Compose Multiplatform is the latest tech from Jetbrain which enable developer to build app in various platform (Android, iOS, Web, Desktop) using one source code base.

I will be trying to recreate a simple version from https://brittanychiang.com/ website. Her website & resume is pretty impressive.

First step we will need to download the project structure. Go to https://kmp.jetbrains.com/, create new project structure & download it.

Open the project file from Android Studio, it will show the project folder :
composeApp
|- androidMain
|- commonMain
|- iosMain
|- wasmJsMain

We will work mostly on commonMain folder, because this folder will be the share code between all platform. Other folder will be source code for specific platform.

To run the mobile version (Android or iOS), we can configure it on Run/Debug configuration and Run it. My Android Studio is Koala 2024, the Run/Debug configuration look like this :

If we run it on Android, it will show

If we run on Iphone simulator will show :

To run it on web, choose Gradle tab on Android Studio side bar. Under composeApp — Tasks — kotlin browser — wasmJsBrowserDevelopmentRun

The app looks working fine on all platform. Now we can start to customize it per our need.

For the next part, we will try to edit the menu on the frontpage.

Sign up to discover human stories that deepen your understanding of the world.

Free

Distraction-free reading. No ads.

Organize your knowledge with lists and highlights.

Tell your story. Find your audience.

Membership

Read member-only stories

Support writers you read most

Earn money for your writing

Listen to audio narrations

Read offline with the Medium app

--

--

Andrea
Andrea

Written by Andrea

Mother on daytime. Android Dev on nighttime. https://andrea-liu87.github.io | ♡ coffee https://ko-fi.com/snufflesrea

No responses yet

Write a response