mirror of https://github.com/sveltejs/svelte
fix: update `state_referenced_locally` message (#15733)
* fix: update state_referenced_locally message * changeset * update messagepull/15738/head
parent
02448a9acd
commit
95a020acea
@ -0,0 +1,5 @@
|
|||||||
|
---
|
||||||
|
'svelte': patch
|
||||||
|
---
|
||||||
|
|
||||||
|
fix: update `state_referenced_locally` message
|
@ -1,26 +1,38 @@
|
|||||||
[
|
[
|
||||||
{
|
{
|
||||||
"code": "state_referenced_locally",
|
"code": "state_referenced_locally",
|
||||||
"message": "State referenced in its own scope will never update. Did you mean to reference it inside a closure?",
|
"message": "This reference only captures the initial value of `count`. Did you mean to reference it inside a derived instead?",
|
||||||
|
"start": {
|
||||||
|
"column": 22,
|
||||||
|
"line": 5
|
||||||
|
},
|
||||||
|
"end": {
|
||||||
|
"column": 27,
|
||||||
|
"line": 5
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"code": "state_referenced_locally",
|
||||||
|
"message": "This reference only captures the initial value of `count`. Did you mean to reference it inside a closure instead?",
|
||||||
"start": {
|
"start": {
|
||||||
"column": 13,
|
"column": 13,
|
||||||
"line": 7
|
"line": 8
|
||||||
},
|
},
|
||||||
"end": {
|
"end": {
|
||||||
"column": 18,
|
"column": 18,
|
||||||
"line": 7
|
"line": 8
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"code": "state_referenced_locally",
|
"code": "state_referenced_locally",
|
||||||
"message": "State referenced in its own scope will never update. Did you mean to reference it inside a closure?",
|
"message": "This reference only captures the initial value of `doubled`. Did you mean to reference it inside a closure instead?",
|
||||||
"start": {
|
"start": {
|
||||||
"column": 13,
|
"column": 13,
|
||||||
"line": 8
|
"line": 9
|
||||||
},
|
},
|
||||||
"end": {
|
"end": {
|
||||||
"column": 20,
|
"column": 20,
|
||||||
"line": 8
|
"line": 9
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
Loading…
Reference in new issue