makeTheme static method
dynamic
makeTheme(})
Creates a new Theme.
Implementation
static makeTheme(String className, String value,
{String folderPath = themesFolder, bool forceCreate = false}) async {
String name = className.replaceAll(RegExp(r'(_?theme)'), "");
String filePath = '$folderPath/${name.snakeCase}_theme.dart';
await _makeDirectory(folderPath);
await _checkIfFileExists(filePath, shouldForceCreate: forceCreate);
await _createNewFile(filePath, value, onSuccess: () {
MetroConsole.writeInGreen('[Theme] ${name.snakeCase}_theme created 🎉');
});
}