Solution Timeline

All versions (edits) of solutions to Template Android app that displays a webpage appear below in the order they were created. Comments that appear under revisions were those created when that particular revision was current.

To see the revision history of a single solution (with diffs), click on the solution number (ie. "#1") in the upper right corner of a solution revision below.

← Bounty Expand all edits

pre-dev qs are:
1. Which platforms and versions will you support?
2. What about offline support?
3. What form factors will you consider?

@source https://www.addthis.com/blog/2014/10/27/7-things-to-consider-when-making-ios-and-android-apps-with-cordova-or-phonegap/

You can use WebView with WebViewClient based class.

Fragment with example WebView:

public class WebViewFragment extends Fragment {

private final String defaultURL = "https://google.com";
private boolean isJavaScriptEnabled = true;
private boolean isLoadImagesAuto = true;


//Public constructor, need to FragmentManager
public WebViewFragment() {}

@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container,
                         Bundle savedInstanceState) {


    //Inflate with resource file without attachment to root
    View view = inflater.inflate(R.layout.fragment_web_view, container, false);

    WebView webView = (WebView) view.findViewById(R.id.webview);

    //We need to have client to use as browser
    webView.setWebViewClient(new MyBrowser());
    webView.getSettings().setLoadsImagesAutomatically(isJavaScriptEnabled);
    webView.getSettings().setJavaScriptEnabled(isLoadImagesAuto);

    //Load default URL
    webView.loadUrl(defaultURL);

    return view;
}

private class MyBrowser extends WebViewClient {
    @Override
    public boolean shouldOverrideUrlLoading(WebView view, String url) {
        view.loadUrl(url);
        return true;
    }
}

}

Full example application project for Android Studio on github

Winning solution