-
Notifications
You must be signed in to change notification settings - Fork 5
Open
Labels
good first issueGood for newcomersGood for newcomers
Description
TypeScript complains that createEffect should have 2 arguments. I believe the following should work without issue:
const [someSignalValue, setSomeSignalValue] = createSignal("foo");
createEffect(() => {
console.log(someSignalValue()); // will log "foo"
});
However, the type definition says that there should be a second argument for a value. I'm not sure why this second argument is required or even what it does. Is it a dependency? And if so, shouldn't it be optional since someSignalValue() is automatically tracked?
Maybe I'm misunderstanding. Thanks!
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
good first issueGood for newcomersGood for newcomers