---
title: "Comment by Alek on \"Pass by Value vs CompositionLocal vs Static CompositionLocal\" | Hashnode"
description: "Hay Vincent, i have problem with compose, i have small app like cart, but i need the price is editable in textfield, i try to resolve but still failed, can you"
url: "https://hashnode.com/posts/pass-by-value-vs-compositionlocal-vs-static-compositionlocal/6439e927f49f45ac4100432d/comment/643fa411f06b44fb4fcfdce9"
---

[Discussion](https://hashnode.com/posts/pass-by-value-vs-compositionlocal-vs-static-compositionlocal/6439e927f49f45ac4100432d)

Comment [Pass by Value vs CompositionLocal vs Static CompositionLocal](https://hashnode.com/posts/pass-by-value-vs-compositionlocal-vs-static-compositionlocal/6439e927f49f45ac4100432d)

[Alek](https://hashnode.com/@alekkuningan)

[Apr 19, 2023](https://hashnode.com/posts/pass-by-value-vs-compositionlocal-vs-static-compositionlocal/6439e927f49f45ac4100432d/comment/643fa411f06b44fb4fcfdce9)

Hay Vincent, i have problem with compose, i have small app like cart, but i need the price is editable in textfield, i try to resolve but still failed, can you give me some insight to do it thanks

[Vincent Tsen](https://hashnode.com/@vtsen)

[Apr 20, 2023](https://hashnode.com/posts/pass-by-value-vs-compositionlocal-vs-static-compositionlocal/6439e927f49f45ac4100432d/comment/643fa411f06b44fb4fcfdce9#reply-64412bc65e1cdf14b5563c7f)

I'm not sure if I can help, but something like this will do.

```
@Composable
fun SimpleFilledTextFieldSample() {
    var text by remember { mutableStateOf("Hello") }

    TextField(
        value = text,
        onValueChange = { text = it },
        label = { Text("Label") }
    )
}
```
