Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -493,7 +493,7 @@ const is_state = (node) => {

/**
* Returns `true` if we're already in a valid call expression, e.g.
* changing an existing `$state()` to `$state.frozen()`
* changing an existing `$state()` to `$state.raw()`
* @type {import("./types").Test}
*/
const is_state_call = (node) => {
Expand Down Expand Up @@ -583,8 +583,8 @@ export const runes = [
{ snippet: '$derived.by', test: is_state_call },
{ snippet: '$effect(() => {\n\t${}\n});', test: is_statement },
{ snippet: '$effect.pre(() => {\n\t${}\n});', test: is_statement },
{ snippet: '$state.frozen(${});', test: is_state },
{ snippet: '$state.frozen', test: is_state_call },
{ snippet: '$state.raw(${});', test: is_state },
{ snippet: '$state.raw', test: is_state_call },
{ snippet: '$bindable()', test: is_bindable },
{ snippet: '$effect.root(() => {\n\t${}\n})' },
{ snippet: '$state.snapshot(${})' },
Expand Down