title: getting context.read() functionality inside build
body: <p>Calling context.read() inside build is not safe. Thus it raises an error but Provider.of(context, listen = false) is allowed for backwards compatibility but it still is unsafe. How can one get the context.read() functionality inside build.</p>
  <p><strong>One solution I found:</strong></p>
  <p>In you model add two values, one that will change and the other will not:</p>
  <pre><code>class MyModel extends ChangeNotifier {
    double value = 45;
    double thisValueWillNeverChange = 45;
  }
  </code></pre>
  <p>In your Widget call <code>value</code> where the value needs to changed and should cause the widget to rebuild but use the <code>thisValueWillNeverChange</code> where you just want to read the initial value and dont want to update the widget.</p>
  <p>You can access both values with context.select() or context.watch().</p>
  <p><strong>Kind of app where I want to implement this functionality:</strong>
  <a href="https://i.stack.imgur.com/biQaI.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/biQaI.png" alt="enter image description here" /></a></p>
  <p>As you can see that the title in the appBar is going to have the <code>thisValueWillNeverChange</code> so it stays static but the text and the slider will change and will use <code>value</code>.</p>
  <p><strong>At the start the app will start with everything having the initial value as 45.0</strong></p>