Name | Date | Size | #Lines | LOC | ||
---|---|---|---|---|---|---|
.. | - | - | ||||
api/ | H | 25-Apr-2025 | - | 151 | 133 | |
src/ | H | 25-Apr-2025 | - | 1,810 | 1,236 | |
.gitignore | H A D | 25-Apr-2025 | 6 | 1 | 1 | |
README.md | H A D | 25-Apr-2025 | 1.1 KiB | 34 | 22 | |
build.gradle.kts | H A D | 25-Apr-2025 | 3.9 KiB | 137 | 88 | |
consumer-rules.pro | HD | 25-Apr-2025 | 0 | |||
gradle.properties | H A D | 25-Apr-2025 | 82 | 3 | 3 | |
proguard-rules.pro | H A D | 25-Apr-2025 | 754 | 21 | 18 |
README.md
1# WebView wrapper for Jetpack Compose 2 3[](https://search.maven.org/search?q=g:com.google.accompanist) 4 5For more information, visit the documentation: https://google.github.io/accompanist/web/ 6 7## Basic Usage 8 9To implement this wrapper there are two key APIs which are needed: WebView, which provides the layout, and rememberWebViewState(url) which provides some remembered state including the URL to display. 10 11The basic usage is as follows: 12```kotlin 13val state = rememberWebViewState("https://example.com") 14 15WebView(state) 16``` 17This will display a WebView in your Compose layout that shows the URL provided. 18 19## Download 20 21```groovy 22repositories { 23 mavenCentral() 24} 25 26dependencies { 27 implementation "com.google.accompanist:accompanist-webview:<version>" 28} 29``` 30 31Snapshots of the development version are available in [Sonatype's `snapshots` repository][snap]. These are updated on every commit. 32 33 [snap]: https://oss.sonatype.org/content/repositories/snapshots/com/google/accompanist/accompanist-web/ 34