> ## Knowledge Base Index
> Fetch the complete knowledge base index at: https://help.funnelflux.pro/sitemap.xml
> Use this file to discover available pages before exploring further.
> Pure-Markdown content can be obtained by appending a '.md' suffix to the content URLs listed in the sitemap (without the trailing slash).

# Overriding default Javascript behaviour

Like with page default tracking params, you can also override the default options used by our global JS code.

**The options that affect our helper functions are:**
-   urlRewrite
-   actionLinkRewrite
-   resolveTokens (global)
-   cookieAllowed
-   isActive

Options can manually overridden by adding a `fluxOptions` object *before* our global JS code.

An example object:
```html
<script>
var fluxOptions = {
  urlRewrite: true,
  actionLinkRewrite: true,
  cookieAllowed: true,
  resolveTokens: ['{country-name}','{isp}'],
  isActive: true
};
</script>
```
## Option Details
Below is a description of each option and its effect.

### urlRewrite
Setting this to false will stop the automatic URL rewriting that happens when a view event tracks.

### actionLinkRewrite
Setting this to false will stop the automatic action link updates that happen when a view event tracks.

### resolveTokens
Tokens to resolve can (and should be) set in events directly, since not all events need tokens in their responses.

However, you can also set a global resolveTokens value and this will result in a default being used in all events.

### cookieAllowed
Setting this to false will prevent cookies being created by our JS.

### isActive
Lastly, setting this to false will cause our JS methods to all cease functioning. You can set this false to prevent tracking, then set it to true once a user gives consent.

If using this, you should manually send a `flux.track("view")` event after `isActive` has been set true.