getBasename function

String getBasename(
  1. String path
)

Gets the part of path after the last separator.

p.basename('path/to/foo.dart'); // -> 'foo.dart'
p.basename('path/to');          // -> 'to'

Trailing separators are ignored.

p.basename('path/to/'); // -> 'to'

Implementation

String getBasename(String path) => basename(path);