set<T> function

Future<void> set<T>(
  1. String path,
  2. dynamic value
)

Set a node data

This will overwrite any data at this location and all child locations.

Data types that are allowed are String, boolean, int, double, Map, List.

If the values are null, they will be deleted.

Implementation

Future<void> set<T>(String path, dynamic value) async {
  await FirebaseDatabase.instance.ref(path).set(value);
}