Understanding a few simple concepts will help you get the most out of Fake:

Use Fake to automate tedious web tasks by dragging discrete Actions into a sequence of runnable, repeatable, savable steps called a Workflow.

- Action - a basic step, or unit of work, to be performed on the current webpage. Fake comes with more than two dozen Actions such as: Load URL, Do JavaScript, Set Value of HTML Element, Submit Form, and many more. Actions come from the Action Library and are combined to form a Workflow.

- Workflow - each Fake browser window has a Workflow seen in the sidebar on the right. Drag Actions from the Action Library into a Workflow to build the sequence of steps you want to perform. Fake Workflows can be saved and reopened using File→Save As… and File→Open…. Workflows are saved with the file extension .fakeworkflow.

- Action Library - this floating panel is a searchable repository of available Actions which can be dragged into your workflow. If you don't see the Action Library panel, select the Window→Action Library (⌥⌘L) main menu item. To add an Action to a Workflow, click and drag one of the Actions in the Action Library to your Workflow. Or, double-clicking an Action in the Action Library will also append it to the end of your frontmost Workflow.

- Variable - an advanced feature of Fake, Variables allow you to store a value once which can then be accessed multiple times in a Workflow. Variables can be set in two ways:

  1. Using the Set Value of Variable Action found in the Action Library.

  2. Using JavaScript by calling `window.fake.set("myVarName", "some value")` in a Do JavaScript Action.

  Once you have set a Variable's value, it may be accessed in one of two ways:

  1. Typing `${myVarName}` into any Action's text field.

  2. Calling `window.fake.get("myVarName")` in a Do JavaScript Action.

- Connecting - many Fake Actions require you to specify an HTML element in the webpage. HTML elements can usually be specified by their `id` or `name` attribute, or by XPath or a CSS selector. Discovering these element specifiers can be difficult and tedious. Fake offers a simple way to Connect an Action to an HTML element on the current page by holding the control key while dragging from an Action to an HTML element on the page.

- Disabled Actions - Any Action in your Workflow can be disabled. Right click on an Action and select Disable Action from the context menu to disable (or Enable Action to re-enable). Alternatively, select the Action and activate Workflow→Toggle Action Disabled (⎇⌘E) in the main menu. When disabled, an Action will appear visually dimmed.

- Collapsed Actions - Since vertical space is at a premium in the Workflow sidebar, any Action can be collapsed. To collapse or expand an Action, click the disclosure triangle in its title bar or just double click the Action. Alternatively, select Workflow→Collapse Action (⎇⌘←) or Workflow→Expand Action (⎇⌘→) from the main menu. When collapsed, Actions show an alternate title with a "hint" as to its current settings.

- Looping with Repeat - To execution portions of your Workflow multiple times, surround some Actions in Repeat and End Repeat Actions. The Repeat Action will continue to loop while its specified condition is true. Breaking out of a Repeat loop early can be done with the Break Action and skipping to the beginning of the next Repeat loop is accomplished with the Continue action. Note that Repeat loops may be nested, and a Break Action placed outside of a Repeat loop will halt execution of the entire Workflow.

- Conditionals with If/Else - Conditional branching is possible with the If, Else If, Else, and End If Actions. Note that Else and Else If Actions are optional, and conditional branches can be nested.

- Handling Errors - Inevitably, your Workflow will encounter fatal errors. A webpage will fail to load, a specified HTML element won't be found, or any number of other bad things will happen. When an Action encounters an Error, it is highlighted red, the Workflow execution stops, and Fake emits an error beep (you can disable these sounds in the Workflow preference pane of the Preferences window). To handle these errors, add a Push Error Handler Action to the beginning of your Workflow and use it to specify some behavior to respond to the error. Selecting Continue in the Push Error Handler Action will allow Workflow execution to continue after the error is handled. A stack of error handler actions is maintained by the Workflow, so popping the most recent error handler Action using the Pop Error Handler Action will restore any previous Push Error Handler Action as the current handler.

- Assertions - Web developers can create automated tests for their Web Applications by leveraging Fake's support for Assertions. After adding a Push Assertion Failure Handler to the beginning, sprinkle your Workflow with Assert Condition Actions which assert expected aspects of the current webpage. For more complex assertion logic, compute a boolean value in a Do JavaScript Action, and set the boolean value as a Fake Variable. Then assert the boolean Variable to be true using an Assert Condition set to JavaScript evals true.

- Wildcards and Regular Expressions - Many Actions which specify attributes or HTML elements on the current webpage accept Wildcards and Regular Expressions as their specifiers. Wildcards allow you to match any run of text using a * character. While Regular Expressions can be used by wrapping a specifier in / / characters.

- Userscripts and Userstyles - allow you to alter any webpage by executing custom JavaScript or evaluating custom CSS on page load. Set this up in the Userstyles window by selecting the Window→Userscripts (⌃⌘U) main menu item. From there, add your custom JavaScript or CSS along with a URL pattern for which it should be matched.