className method
Return the class name from the base name
and keys
.
Implementation
String className(
final String name, [
final Iterable<String> keys = const Iterable<String>.empty(),
]) {
final List<String> $keys = <String>[...keys, name];
if (!convert && $keys.length == 1) {
$keys.insert(0, $keys.removeAt(0).normalize());
}
return $keys
.map(
(final String key) =>
(convert ? key.toCamelCase() : key).capitalize(),
)
.join();
}