imSanjaySoni / Inshorts-Clone-The-News-App

inshorts News App Clone with flutter and newsapi.org API

Home Page:https://drive.google.com/file/d/1D0U3uX1GGse8BMWsQ-NIGgEIPkOJNL0a/view?usp=sharing

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

The name 'Router' is defined in the libraries '

vipuluthaiah opened this issue · comments

The name 'Router' is defined in the libraries 'package:flutter/src/widgets/router.dart' and 'package:inshort_clone/routes/routesgr.dart'.
Try using 'as prefix' for one of the import directives, or hiding the name from all but one of the imports.
image
image

Hey, this error comes with the new update of Flutter SDK, because the Router is a preexisting class of SDK.

You can fix it in two ways..

lib/routes/routes.dart

  • replace the Router class with a different name and run the build_runner command, and replace all imports with the newly generated routes.gr.dart file.

  • IMG20201218231159.jpg

Yeh i have already done that..But m8 it works on debug ,But when i run (flutter build apk) apk have many problem

Like only some features are loading .Eg:Only news load rest there is no option to go back

Screenshot_20201219-112807
this is the apk .I cant see the back button and many other features r missing