title: Flutter Hooks: Getting error while using useEffect with TextEditingController
body: <p>I want to use useEffect with TextEditingController instead of useTextEditingController.</p>
  <p>Error: late Initialization Error. Am I not writing init and disposing correctly?</p>
  <pre><code>class EffectTest extends HookWidget {
    const EffectTest({super.key});
  
    @override
    Widget build(BuildContext context) {
      late TextEditingController controller;
  
      useEffect(
        () {
          controller = TextEditingController();
  
          return () {
            controller.clear();
          };
        },
        [],
      );
  
      return MaterialApp(
        home: Scaffold(
          body: Column(
            children: [
              Text(controller.value.text),
              TextField(
                controller: controller,
                onSubmitted: (value) {
                  print(controller.value.text);
                },
              ),
            ],
          ),
        ),
      );
    }
  }
  
  </code></pre>