to static method

GTween to(
  1. Object? target,
  2. double duration,
  3. Map? vars, [
  4. GVars? nanoVars,
])

Creates a GTween that animates the properties of the target object from its current values to the values specified in the vars map over the specified duration. Is a shortcut to start a tween on target.

If nanoVars is provided, the GTween will be initialized with the additional configuration options specified in nanoVars.

Returns the created GTween instance.

Implementation

static GTween to(
  Object? target,
  double duration,
  Map? vars, [
  GVars? nanoVars,
]) {
  nanoVars ??= GVars();
  return GTween(target, duration, vars, nanoVars);
}