fromAsset static method

Future<SkeletonDrawable> fromAsset(
  1. String atlasFile,
  2. String skeletonFile, {
  3. AssetBundle? bundle,
})

Implementation

static Future<SkeletonDrawable> fromAsset(String atlasFile, String skeletonFile, {AssetBundle? bundle}) async {
  bundle ??= rootBundle;
  var atlas = await Atlas.fromAsset(atlasFile, bundle: bundle);
  var skeletonData = await SkeletonData.fromAsset(atlas, skeletonFile, bundle: bundle);
  return SkeletonDrawable(atlas, skeletonData, true);
}