Looking For Anything Specific?

ads header

Only 5 minutes enough! to do a crazy app .believe me!

 

Only 5 minutes enough! to do a crazy app .believe me!

Download and rate the app from the Google Play Store.

https://play.google.com/store/apps/details?id=com.academind.SriLankan_NewsPapers

I recently learned about the webview widget. This widget inspired me to create the app. So, in general, I understand the fundamentals of flutter. If you don’t know, no worries, read my flutter article. 


So, today, there is a major issue? We are in lockdown in Sri Lanka. As a result, we are unable to go outside or purchase newspapers to read. As a result, we truly think that every newspaper should have their own website, which they should maintain and update on a daily basis. As a result, I planned to choose newspaper because the majority of people liked to read news in that paper. In Sri Lanka, we use three languages to communicate, or more specifically, three types of languages: Tamil, Sinhala, and English (Common Language)



I’ve chosen the top four newspapers in each language.

I used the webview widget in this case.





body: Column(
children: [
LinearProgressIndicator(
color: Colors.red,
backgroundColor: Colors.black,
value: progress,
),
Expanded(
child: WebView(
javascriptMode: JavascriptMode.unrestricted,
initialUrl: 'https://eelanadu.lk/',
onWebViewCreated: (controller) {
this.controller = controller;
controller.evaluateJavascript(
"document.getElementsByTagName('header')[0].style.display='none'");
controller.evaluateJavascript(
"document.getElementsByTagName('footer')[0].style.display='none'");
},
onProgress: (progress) => setState(() {
this.progress = progress / 100;
}),
),
),
],
),



Here, we set LinearProgressIndicator to indicate whether or not we arrived at the page. Here, we use the WebView widget inside the widget, and there are some things we’ve made sure of. Set the javascriptMode to unrestricted at first by using the javascriptMode property, and then set the URL in the initialUrl property.


I’ve also used some ListViewBuilder to create a list view, so that’s enough to make an app. Small stones are also used to construct houses.


https://www.youtube.com/watch?v=fp0sVPmZHbA






Post a Comment

0 Comments