skip to Main Content

I’m using Google Books API to make it an application program using flutter on android studio, but the displayed image can’t be loaded on the URL with the following description coming out;

Running with unsound null safety
For more information see https://dart.dev/null-safety/unsound-null-safety
Debug service listening on ws://127.0.0.1:53771/9sOn-nopEoY=/ws
XMLHttpRequest error.

The following ImageCodecException was thrown resolving an image codec:
Failed to load network image.
Image URL: http://books.google.com/books/content?id=WiEpzgEACAAJ&printsec=frontcover&img=1&zoom=1&source=gbs_api
Trying to load an image from another domain? Find answers at:
https://flutter.dev/docs/development/platform-integration/web-images

When the exception was thrown, this was the stack: 
Image provider: NetworkImage("http://books.google.com/books/content?id=WiEpzgEACAAJ&printsec=frontcover&img=1&zoom=1&source=gbs_api", scale: 1)
Image key: NetworkImage("http://books.google.com/books/content?id=WiEpzEACAAJ&printsec=frontcover&img=1&zoom=1&source=gbs_api", scale: 1)
====================================================================================================```

[display of errors that occur in screenshots][1]

[display of errors that occur in screenshots][2]

  [1]: https://i.stack.imgur.com/189rY.png
  [2]: https://i.stack.imgur.com/ujA7s.png

does anyone know where the error from the program?

2

Answers


  1. when I check the URL on my browser, it says no image available. that might be the cause.

    Login or Signup to reply.
  2. Image cannot be loaded from other domains like error says. Like the link from the error suggests HtmlElementView can be used to overcome this.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search