namhyun-gu / naver-map-compose

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

naver-map-compose

Download

Getting Started

Add dependency codes to your module level build.gradle file.

dependencies {
  implementation 'com.github.namhyungu:naver-map-compose:0.1.0'
  implementation "com.naver.maps:map-sdk:3.9.1"
}

Usage

  • Use NaverMapView composable function.
NaverMapView(
  modifier = Modifier,
  onMapReady = { map ->
    // Initialize NaverMap
  }
)

References

Example

screenshot

class MainActivity : AppCompatActivity() {
    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
        setContent {
            ExampleTheme {
                // A surface container using the 'background' color from the theme
                Scaffold(
                    topBar = {
                        TopAppBar(title = { Text("NaverMapCompose") })
                    }
                ) {
                    NaverMapView(onMapReady = {})
                }
            }
        }
    }
}

License

Copyright 2020 Namhyun, Gu

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

   http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

About


Languages

Language:Kotlin 100.0%