@veribenim/vue 1.0.0 → 3.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +62 -0
- package/package.json +4 -3
package/README.md
ADDED
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
# @veribenim/vue
|
|
2
|
+
|
|
3
|
+
> Veribenim KVKK & GDPR çerez onayı SDK — Vue 3
|
|
4
|
+
|
|
5
|
+
[](https://www.npmjs.com/package/@veribenim/vue)
|
|
6
|
+
[](https://opensource.org/licenses/MIT)
|
|
7
|
+
|
|
8
|
+
## Kurulum
|
|
9
|
+
|
|
10
|
+
```bash
|
|
11
|
+
npm install @veribenim/vue
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
## Kurulum (main.ts)
|
|
15
|
+
|
|
16
|
+
```ts
|
|
17
|
+
import { createApp } from 'vue';
|
|
18
|
+
import { VeribenimPlugin } from '@veribenim/vue';
|
|
19
|
+
import App from './App.vue';
|
|
20
|
+
|
|
21
|
+
const app = createApp(App);
|
|
22
|
+
|
|
23
|
+
app.use(VeribenimPlugin, {
|
|
24
|
+
token: 'BURAYA_TOKEN_YAPISTIRIN',
|
|
25
|
+
lang: 'tr',
|
|
26
|
+
});
|
|
27
|
+
|
|
28
|
+
app.mount('#app');
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
## Composable
|
|
32
|
+
|
|
33
|
+
```vue
|
|
34
|
+
<script setup>
|
|
35
|
+
import { useVeribenim } from '@veribenim/vue';
|
|
36
|
+
|
|
37
|
+
const { preferences, accept, decline, client } = useVeribenim();
|
|
38
|
+
</script>
|
|
39
|
+
|
|
40
|
+
<template>
|
|
41
|
+
<div v-if="!preferences">
|
|
42
|
+
<button @click="accept()">Tümünü Kabul Et</button>
|
|
43
|
+
<button @click="decline">Reddet</button>
|
|
44
|
+
</div>
|
|
45
|
+
</template>
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
## Form Rızası
|
|
49
|
+
|
|
50
|
+
```ts
|
|
51
|
+
const { client } = useVeribenim();
|
|
52
|
+
|
|
53
|
+
await client.logFormConsent({
|
|
54
|
+
formName: 'newsletter',
|
|
55
|
+
consented: true,
|
|
56
|
+
consentText: 'E-posta listesine katılmayı onaylıyorum.',
|
|
57
|
+
});
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
## Lisans
|
|
61
|
+
|
|
62
|
+
MIT © [Pariette](https://veribenim.com)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@veribenim/vue",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "3.0.0",
|
|
4
4
|
"description": "Veribenim KVKK/GDPR çerez onayı SDK - Vue 3",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"kvkk",
|
|
@@ -23,10 +23,11 @@
|
|
|
23
23
|
}
|
|
24
24
|
},
|
|
25
25
|
"files": [
|
|
26
|
-
"dist"
|
|
26
|
+
"dist",
|
|
27
|
+
"README.md"
|
|
27
28
|
],
|
|
28
29
|
"dependencies": {
|
|
29
|
-
"@veribenim/core": "
|
|
30
|
+
"@veribenim/core": "3.0.0"
|
|
30
31
|
},
|
|
31
32
|
"peerDependencies": {
|
|
32
33
|
"vue": ">=3.0.0"
|