Welcome back.
We created the project in Google Maps platform.
We added the dependency in build file.
Now our project is ready to use and create the Google Maps composable function inside the set content.
Remove this scaffold.
Also, you can remove the theme theme and start with Google Map.
The Google Map composable function is part of the Maps Compose library by Google.
It allows you to embed and control a Google map directly within your Jetpack Compose UI, without needing
to use XML layouts or map view.
The composable integrates seamlessly with other compose UI elements.
If we go to this composable Ctrl and left click, we can get this Google Mapkit file.
We have a lot of things we can customize with those parameters of the Google map.
Declarative.
You describe what the map should look like, then compose handles the rest.
Customizable supports markers, polygons, polylines, camera movement, and more.
Lifecycle aware handles lifecycle events automatically, so you don't need to manage the map's lifecycle
manually.
As usual, we'll start with those modifiers and the modifier controls the layout and sizing of the map.
We can use fill maximum size.
We can set the padding.
The camera position state manages the map's view position, latitude, longitude, zoom, tilt, buffering,
and others.
So when using animate smoothly move the camera move instantly jumps to the to the position we're going
to skip.
Uh, the parameters that we're not, uh, they are least important and they are not very important,
uh, to to discuss or use properties defines map behavior and UI settings.
For example, we can set the map style you can for normal hybrid terrain shows 3D building, traffic
data overlay, indoor maps and minimum zoom level.
Maximum zoom zoom level, all those things we can customize in the maps properties.
So if you if you notice here we have this class map properties control and left click.
We have those parameters we can set is building enabled indoor enabled location traffic longitude and
latitude bounds map style options map type.
Also we can get the map type inside the map type we have non normal satellite terrain hybrid.
We're going to discuss those types later on.
So don't worry.
We're going to discuss the zoom the camera, the style longitude and latitude and so on okay UI settings
um the controls user interactions settings on map loaded called when the map is fully loaded on map.
A click called when the user taps anywhere on the map.
On marker, click and on My Location button, click marker click or on map.
Click all those handlers we're going to discuss and handle and lecture about them in the next couple
of videos.
On camera move, we can discuss the camera position state later on and uh, and customize it later on.
Also, we have the content allows adding custom compose UI overlays, for example buttons, info windows,
and others.
Okay, let's start using the Google map here.
Start with modifier fill maximum size.
This is the modifier we can run our application now.
Make sure you select the API and not signing report and click run and our app crashes.
We open the Logcat.
We missed the API key.
So we have the fatal exception API key not found.
Check that this code is added in the application element of the Android manifest.
Copy this metadata.
Go to manifest inside the application tag.
Paste this meta data.
Open the notepad.
Copy the API key and replace it here.
Okay, this is a very important step.
This will link our application with Google Cloud and use the maps SDK.
Run again and here we go.
Congratulations.
This is our Google map.
In order to use it and without uh, without uh, any errors, use the permission internet run again.
And this will prevent any errors.
Okay, so congratulations guys.
We created our very first Android application with the maps as the.