title: how to edit value at the child widget
body: <p>i try to edit the value of the child widget, i can do it with StatefulWidget parent but i want to do it with StatelessWidget parent and without using global value </p>
  
  <pre><code>    class Homepage extends StatelessWidget {
    @override
    Widget build(BuildContext context) {
      return Scaffold(
        appBar: AppBar(
          actions: &lt;Widget&gt;[
            FlatButton(child: Text('addFile'), onPressed: () {}),
            FlatButton(child: Text('deleteFile'), onPressed: () {})
          ],
        ),
        body: Child(),
      );
    }
  }
  
  class Child extends StatefulWidget {
    @override
    _ChildState createState() =&gt; _ChildState();
  }
  
  class _ChildState extends State&lt;Child&gt; {
    var hasFile = true;
    @override
    Widget build(BuildContext context) {
      return hasFile ? Text('has a file') : Text("no File");
    }
  }
  </code></pre>