In this article we will learn about some of the frequently asked TypeScript programming questions in technical like “how to add image from assets inside as a decoration image in container” Code Answer’s. When creating scripts and web applications, error handling is an important part. If your code lacks error checking code, your program may look very unprofessional and you may be open to security risks. Error or stack handling on typescript was simple and easy. An error message with filename, line number and a message describing the error is sent to the browser. This tutorial contains some of the most common error checking methods in Typescript. Below are some solution about “how to add image from assets inside as a decoration image in container” Code Answer’s.
how to add image from assets inside as a decoration image in container
xxxxxxxxxx
new Container(
width: 100.00,
height: 100.00,
decoration: new BoxDecoration(
image: new DecorationImage(
image: ExactAssetImage('assets/example.png'),
fit: BoxFit.fitHeight,
),
));
how to add image from assets inside as a decoration image in container
xxxxxxxxxx
Container(
height: 120.0,
width: 120.0,
decoration: BoxDecoration(
image: DecorationImage(
image: AssetImage(
'assets/assets/alucard.jpg'),
fit: BoxFit.fill,
),
shape: BoxShape.circle,
),
)