Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 9 additions & 9 deletions website/docs/sdk-reference/community/vue.mdx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
id: vue
title: ConfigCat SDK for Vue.js
description: Unofficial Vue SDK for ConfigCat Feature Flags. Based on ConfigCat's JavaScript SDK.
description: Unofficial Vue SDK for ConfigCat feature flags. Based on ConfigCat's JavaScript SDK.
---

export const VueSchema = require('@site/src/schema-markup/sdk-reference/community/vue.json');
Expand Down Expand Up @@ -65,7 +65,7 @@ Pass the feature flag key as a prop:
</template>
```

Optionally, the `FeatureWrapper` component also provides an `#else` and `#loading` template. Components or HTML elements can be included within these templates that would display when the feature flag is **turned off** or **loading** respectively.
Optionally, the `FeatureWrapper` component also provides `#else` and `#loading` templates. Components or HTML elements can be included within these templates that would display when the feature flag is **turned off** or **loading** respectively.

```html
<FeatureWrapper
Expand All @@ -91,7 +91,7 @@ Optionally, the `FeatureWrapper` component also provides an `#else` and `#loadin

### Specifying a polling mode

Polling modes are used to control how often ConfigCat's SDK client downloads the values of feature flags from ConfigCat's servers. The default polling mode is `AutoPoll`. Auto Polling fetches the latest feature flag values every 60 seconds by default. To change this, Specify a polling mode and set the polling interval (in seconds) via the `pollIntervalSeconds` property.
Polling modes are used to control how often ConfigCat's SDK client downloads the values of feature flags from ConfigCat's servers. The default polling mode is `AutoPoll`. Auto polling fetches the latest feature flag values every 60 seconds by default. To change this, specify a polling mode and set the polling interval (in seconds) via the `pollIntervalSeconds` property.

Import:

Expand All @@ -111,7 +111,7 @@ app.use(ConfigCatPlugin, {
});
```

`pollingMode` can be set to: `PollingMode.AutoPoll`, `PollingMode.ManualPoll` and `PollingMode.LazyLoad`
`pollingMode` can be set to: `PollingMode.AutoPoll`, `PollingMode.ManualPoll` and `PollingMode.LazyLoad`.

> See documentation [here](../../advanced/caching.mdx).

Expand All @@ -121,7 +121,7 @@ You may want to log the actions of the underlying ConfigCat SDK client. To do th

> See documentation [here](../js/browser.mdx#logging).

Add `createConsoleLogger`, and `LogLevel` to your import:
Add `createConsoleLogger` and `LogLevel` to your import:

```js
import { createConsoleLogger, LogLevel } from "configcat-vue";
Expand Down Expand Up @@ -149,8 +149,8 @@ app.use(ConfigCatPlugin, {
| ----- | ------------------------------------------------------- |
| Off | Nothing gets logged. |
| Error | Only error level events are logged. |
| Warn | Default. Errors and Warnings are logged. |
| Info | Errors, Warnings and feature flag evaluation is logged. |
| Warn | Default. Errors and warnings are logged. |
| Info | Errors, warnings and feature flag evaluations are logged. |
| Debug | All of the above plus debug info is logged. |

### Specifying a User Object
Expand All @@ -168,7 +168,7 @@ import { User } from 'configcat-vue';

// Define the User Object
const user = { identifier: 'john@example.com' };
const userObject = ref<User>(user)
const userObject = ref<User>(user);

</script>
```
Expand All @@ -187,7 +187,7 @@ Pass it to the `FeatureWrapper` component:

### Listening to flag changes emitted from the FeatureWrapper component

When a feature flag is toggled ON or OFF in the [ConfigCat Dashboard](https://app.configcat.com) the `FeatureWrapper` component emits the updated feature flag value. How quickly the updated value is emitted depends on the polling interval set in the `clientOptions` property of the `ConfigCatPlugin`.
When a feature flag is toggled ON or OFF in the [ConfigCat Dashboard](https://app.configcat.com), the `FeatureWrapper` component emits the updated feature flag value. How quickly the updated value is emitted depends on the polling interval set in the `clientOptions` property of the `ConfigCatPlugin`.

Listen and handle changes using `@flag-value-changed`:

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
id: vue
title: ConfigCat SDK for Vue.js
description: Unofficial Vue SDK for ConfigCat Feature Flags. Based on ConfigCat's JavaScript SDK.
description: Unofficial Vue SDK for ConfigCat feature flags. Based on ConfigCat's JavaScript SDK.
---

export const VueSchema = require('@site/src/schema-markup/sdk-reference/community/vue.json');
Expand Down Expand Up @@ -65,7 +65,7 @@ Pass the feature flag key as a prop:
</template>
```

Optionally, the `FeatureWrapper` component also provides an `#else` and `#loading` template. Components or HTML elements can be included within these templates that would display when the feature flag is **turned off** or **loading** respectively.
Optionally, the `FeatureWrapper` component also provides `#else` and `#loading` templates. Components or HTML elements can be included within these templates that would display when the feature flag is **turned off** or **loading** respectively.

```html
<FeatureWrapper
Expand All @@ -91,7 +91,7 @@ Optionally, the `FeatureWrapper` component also provides an `#else` and `#loadin

### Specifying a polling mode

Polling modes are used to control how often ConfigCat's SDK client downloads the values of feature flags from ConfigCat's servers. The default polling mode is `AutoPoll`. Auto Polling fetches the latest feature flag values every 60 seconds by default. To change this, Specify a polling mode and set the polling interval (in seconds) via the `pollIntervalSeconds` property.
Polling modes are used to control how often ConfigCat's SDK client downloads the values of feature flags from ConfigCat's servers. The default polling mode is `AutoPoll`. Auto polling fetches the latest feature flag values every 60 seconds by default. To change this, specify a polling mode and set the polling interval (in seconds) via the `pollIntervalSeconds` property.

Import:

Expand All @@ -111,7 +111,7 @@ app.use(ConfigCatPlugin, {
});
```

`pollingMode` can be set to: `PollingMode.AutoPoll`, `PollingMode.ManualPoll` and `PollingMode.LazyLoad`
`pollingMode` can be set to: `PollingMode.AutoPoll`, `PollingMode.ManualPoll` and `PollingMode.LazyLoad`.

> See documentation [here](../../advanced/caching.mdx).

Expand All @@ -121,7 +121,7 @@ You may want to log the actions of the underlying ConfigCat SDK client. To do th

> See documentation [here](../js.mdx#logging).

Add `createConsoleLogger`, and `LogLevel` to your import:
Add `createConsoleLogger` and `LogLevel` to your import:

```js
import { createConsoleLogger, LogLevel } from "configcat-vue";
Expand Down Expand Up @@ -149,8 +149,8 @@ app.use(ConfigCatPlugin, {
| ----- | ------------------------------------------------------- |
| Off | Nothing gets logged. |
| Error | Only error level events are logged. |
| Warn | Default. Errors and Warnings are logged. |
| Info | Errors, Warnings and feature flag evaluation is logged. |
| Warn | Default. Errors and warnings are logged. |
| Info | Errors, warnings and feature flag evaluations are logged. |
| Debug | All of the above plus debug info is logged. |

### Specifying a User Object
Expand All @@ -168,7 +168,7 @@ import { User } from 'configcat-vue';

// Define the User Object
const user = new User('john@example.com');
const userObject = ref<User>(user)
const userObject = ref<User>(user);

</script>
```
Expand All @@ -187,7 +187,7 @@ Pass it to the `FeatureWrapper` component:

### Listening to flag changes emitted from the FeatureWrapper component

When a feature flag is toggled ON or OFF in the [ConfigCat Dashboard](https://app.configcat.com) the `FeatureWrapper` component emits the updated feature flag value. How quickly the updated value is emitted depends on the polling interval set in the `clientOptions` property of the `ConfigCatPlugin`.
When a feature flag is toggled ON or OFF in the [ConfigCat Dashboard](https://app.configcat.com), the `FeatureWrapper` component emits the updated feature flag value. How quickly the updated value is emitted depends on the polling interval set in the `clientOptions` property of the `ConfigCatPlugin`.

Listen and handle changes using `@flag-value-changed`:

Expand Down
Loading