RiveAnimation.network constructor
const
RiveAnimation.network(
- String url, {
- String? artboard,
- List<
String> animations = const [], - List<
String> stateMachines = const [], - BoxFit? fit,
- Alignment? alignment,
- Widget? placeHolder,
- bool antialiasing = true,
- bool useArtboardSize = false,
- Rect? clipRect,
- List<
RiveAnimationController> controllers = const [], - OnInitCallback? onInit,
- Map<
String, String> ? headers, - RiveHitTestBehavior behavior = RiveHitTestBehavior.opaque,
- ObjectGenerator? objectGenerator,
- Key? key,
Creates a new RiveAnimation from a URL over HTTP
Example:
return RiveAnimation.network('https://cdn.rive.app/animations/vehicles.riv');
Implementation
const RiveAnimation.network(
String url, {
this.artboard,
this.animations = const [],
this.stateMachines = const [],
this.fit,
this.alignment,
this.placeHolder,
this.antialiasing = true,
this.useArtboardSize = false,
this.clipRect,
this.controllers = const [],
this.onInit,
this.headers,
this.behavior = RiveHitTestBehavior.opaque,
this.objectGenerator,
Key? key,
}) : name = url,
file = null,
src = _Source.network,
super(key: key);