content property

  1. @override
String get content
override

Store the content that will be written to the file in a String or Future

Implementation

@override
String get content => '''import 'package:flutter/material.dart';
import 'package:mega_commons_dependencies/mega_commons_dependencies.dart';

import '../controllers/${_fileName}_controller.dart';

class ${_fileName.pascalCase}View extends GetView<${_fileName.pascalCase}Controller> {
const ${_fileName.pascalCase}View({Key? key}) : super(key: key);
@override
Widget build(BuildContext context) {
  return Scaffold(
    appBar: AppBar(
      title: const Text('${_fileName.pascalCase}View'),
      centerTitle: true,
    ),
    body: const Center(
      child: Text(
        '${_fileName.pascalCase}View is working',
        style: TextStyle(fontSize: 20),
      ),
    ),
  );
}
}''';