Skip to main content

JetStart VS Code Extension

The JetStart Kotlin & Compose Snippets extension is designed to give Android developers a fast, React-like scaffolding experience directly in VS Code. It provides robust, package-aware, and import-aware snippets for Kotlin and Jetpack Compose.

Features​

  • 🚀 Smart Snippets: Quick templates for Classes, ViewModels, Composables, Room Entities, and more.
  • 📦 Package Awareness: Automatically detects and inserts the correct package declaration based on your folder structure.
  • 📥 Auto-Imports: Automatically adds required imports to the top of the file when you use a snippet.
  • 🔍 Compose Import Helper: Quick suggestions for missing Compose and AndroidX imports.

Installation​

Since the extension is currently in beta, you can install it directly by downloading the .vsix package.

1. Download the Extension​

Download the latest version of the JetStart extension:

📥 Download JetStart VS Code Extension (.vsix)

2. Install in VS Code​

  1. Open Visual Studio Code.
  2. Go to the Extensions view (Ctrl+Shift+X).
  3. Click the More Actions (...) menu in the top-right corner of the Extensions bar.
  4. Select Install from VSIX...
  5. Locate and select the jetstart-kotlin-snippets.vsix file you just downloaded.
  6. Restart VS Code if prompted.

Common Snippets​

Type these prefixes in any .kt file to trigger the snippets:

PrefixWhat you get
ktcClass with auto-detected package name
ktdcData class
ktscSealed class (Success/Error/Loading)
ktecEnum class
ktvmViewModel + StateFlow + coroutine scope
kthiltvmHilt ViewModel + @Inject
ktrepRepository class
ktentRoom @Entity
ktdaoRoom @Dao
ktdbRoom Database singleton
ktcf@Composable function
ktcfs@Composable + remember state
ktprev@Preview composable
ktscaffoldFull Scaffold + TopAppBar + FAB
ktlazycolLazyColumn with items
ktlazyrLazyRow with items
ktlazysgridLazyVerticalStaggeredGrid
ktcardMaterial3 Card
ktrow / ktcolRow / Column
ktalertdAlertDialog
ktbottomsheetModalBottomSheet
kttabTopAppBar
ktnavNavHost setup
ktstatevar x by remember { mutableStateOf(...) }
ktsflowMutableStateFlow + StateFlow pair
ktcollectcollectAsState()
ktlaunch / ktsideef / ktdisposable / ktderivedEffects
ktcoro / ktio / ktasyncCoroutines
ktfun / ktsfun / ktef / ktlambdaFunctions
ktwhen / ktwhenresultwhen expressions

Auto-features​

  • Smart Package Insertion: Open a new empty .kt file and the package name is auto-inserted based on the directory structure.
  • Instant Auto-Imports: Type an identifier like mutableStateOf and the import suggestion appears immediately.
  • Deep Support: Works for 150+ Compose/Kotlin identifiers across Room, Hilt, Navigation, Coroutines, and more.

How it Works (and Automation)​

A common question is: Why use a manual import map instead of an official source?

Unlike Android Studio, which builds a heavy local index of all your dependencies (often consuming significant RAM), JetStart's VS Code extension is designed for instant, zero-latency feedback.

  1. The "Official" Way: Standard IDEs use the Language Server Protocol (LSP) to scan your Gradle dependencies. While powerful, this can be slow and often fails in complex environments.
  2. The JetStart Way: We use a curated high-performance map of over 150 common Compose and Kotlin identifiers. This gives you instant suggestions the moment you type, without waiting for a background indexer.

Automating Updates​

To keep this map up-to-date without manual effort, we are working on a Sync Runner script that will:

  • Automatically scan the build.gradle classpath.
  • Extract public identifiers from AndroidX and Kotlin libraries.
  • Regenerate the mapping files for the extension.

This ensures you always have the latest Material3 and Compose symbols without the performance cost of a full IDE indexer.


For the best experience, we recommend using this extension alongside other Kotlin tools for full IDE features like go-to-definition and linting.

Complementary Extensions​

JetStart's extension works perfectly alongside the following popular Kotlin extensions:

Why use JetStart's extension?
While the extensions above provide great language support, JetStart's extension is uniquely focused on Android/Compose speed:

  • Instant Imports: No waiting for the Language Server to index; imports are added instantly.
  • Android-First Snippets: Tailored templates for M3 Scaffold, ViewModels, and Room that aren't available in generic Kotlin packs.