# useHook static method

void useHook(

1. ApplicationHook hook,
2. Runnable action

)

Executes an action with a specific application hook.

Application hooks allow customization of framework behavior during application creation and execution.

### Usage:

    JetApplication.useHook(MyApplicationHook(), () {
      JetApplication.run(MyApplication, args);
    });

`hook` the application hook to use `action` the action to execute with the hook active

## Implementation

    static void useHook(ApplicationHook hook, Runnable action) {
    		useThrowableHook(hook, () {
    			action.run();
    			return null;
    		});
    	}