Skip to content

[Content]: Confusing language for useAction #1192

Open
@klequis

Description

@klequis

📚 Subject area/topic

/solid-router/concepts/actions.mdx

📋 Page(s) affected (or suggested, for new content)

https://docs.solidjs.com/solid-router/concepts/actions

📋 Description of content that is out-of-date or incorrect

Paragraph: "To use the action, you can call it from within a component using useAction. This returns a function that can be called with the necessary arguments to trigger the action."

To me this: "with the necessary arguments to trigger the action.", says there are 'arguments that are necessary/required to trigger an action. When I first read it I wondered, "what are those arguments?".

The arguments are not needed to "trigger an action", but if the function wrapped with action has parameters, you can include them.

I'm not sure if pointing out that the arguments can be sent is necessary.

I tried to come up with clearer wording but couldn't.

Maybe something like: "This returns a function that can be called to trigger the action, along with any parameters required by the function wrapped by 'action'.

🖥️ Reproduction in StackBlitz (if reporting incorrect content or code samples)

No response

Metadata

Metadata

Assignees

Labels

in progressSomeone is currently working on the issue.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions