Below is a list of all available over_react snippets and their Triggers for Webstorm/IntelliJ and VS Code.
Trigger | Content |
---|---|
orStless |
Stateless component skeleton with abbreviated props declaration |
orStful |
Stateful component skeleton with abbreviated props and state declarations |
orStlessConnect |
Stateless component skeleton with the generated factory wrapped in connect |
orFunc |
Function component skeleton with abbreviated props declaration |
orAdvStless |
Stateless component skeleton with a props class alias |
orAdvStful |
Stateful component skeleton with props and state class aliases |
orAdvFunc |
Function component skeleton with props class alias |
-
Copy the command below and run it in your terminal.
curl https://raw.githubusercontent.com/Workiva/over_react/master/snippets/snippets.xml | pbcopy
-
Open preferences and select "Editor" > "Live Templates"
-
(Optional) Create a new "OverReact Snippets" group by clicking the "+" button in the
upper right corner and selecting "Template Group..." -
Right click on your new (or an existing) template group and select Paste.
-
Use any "prefix" or "trigger" from the table above in any ".dart" file to invoke a snippet
-
Press "tab" to move to and set the next variable.
-
Copy the command below and run it in your terminal.
curl https://raw.githubusercontent.com/Workiva/over_react/master/snippets/snippets.json | pbcopy
-
Click on "Code", select "Preferences" and select "User Snippets"
-
Select "New Global Snippet file..."
-
Name the file something meaningful like "OverReact Snippets"
-
Select all of the boiler plate in the snippet file just created and replace it by pasting the
VS Code snippets json copied after running the command in step 1 -
Use any "prefix" or "trigger" from the table above in any ".dart" file to invoke a snippet
-
Press "tab" to move to and set the next variable.