Skip to content

Example project to showcase how to load a local html file into a webview within an Android application

License

Notifications You must be signed in to change notification settings

edent/Android-WebView-Example

 
 

Repository files navigation

Android-WebView-Example

Example project to showcase how to load a local html file into a webview within an Android application

Mainly written because edent asked the question

Application consits of one Web View with the layout defined in app/src/main/res/layout/activity_main.xml, and an activity to load the html app/src/main/java/site/zpweb/webviewsample/MainActivity.kt.

The HTML file is stored in the asset folder app/src/main/assets

By loading the URL using the file schema relative linking to files within the asset folder "should" (untested) work just fine.

See WebView for more details.

About

Example project to showcase how to load a local html file into a webview within an Android application

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Kotlin 96.7%
  • HTML 3.3%