docs: add framework support document
This commit is contained in:
parent
d8b23a7468
commit
18027170b8
4
website/docs/website/framework/_category_.json
Normal file
4
website/docs/website/framework/_category_.json
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
{
|
||||||
|
"label": "Framework",
|
||||||
|
"position": 2
|
||||||
|
}
|
26
website/docs/website/framework/docusaurus.md
Normal file
26
website/docs/website/framework/docusaurus.md
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
---
|
||||||
|
sidebar_position: 1
|
||||||
|
---
|
||||||
|
|
||||||
|
# Use in Docusaurus
|
||||||
|
|
||||||
|
In `docusaurus.config.js`:
|
||||||
|
|
||||||
|
|
||||||
|
```js
|
||||||
|
/** @type {import('@docusaurus/types').Config} */
|
||||||
|
const config = {
|
||||||
|
// ...
|
||||||
|
|
||||||
|
scripts: [
|
||||||
|
{
|
||||||
|
src: 'https://<your domain>/tracker.js',
|
||||||
|
async: true,
|
||||||
|
defer: true,
|
||||||
|
'data-website-id': '<your-website-id>',
|
||||||
|
},
|
||||||
|
],
|
||||||
|
};
|
||||||
|
|
||||||
|
module.exports = config;
|
||||||
|
```
|
@ -14,13 +14,13 @@ the script look like below:
|
|||||||
<script async defer src="https://<your-self-hosted-domain>/tracker.js" data-website-id="xxxxxxxxxxxxx"></script>
|
<script async defer src="https://<your-self-hosted-domain>/tracker.js" data-website-id="xxxxxxxxxxxxx"></script>
|
||||||
```
|
```
|
||||||
|
|
||||||
you can get this script code from your tianji website list
|
you can get this script code from your **Tianji** website list
|
||||||
|
|
||||||
## Report Event
|
## Report Event
|
||||||
|
|
||||||
Tianji provide a simple way to report user click event, its easy to help you track which action user like and often to use.
|
**Tianji** provide a simple way to report user click event, its easy to help you track which action user like and often to use.
|
||||||
|
|
||||||
This is a very common method in website analysis. You can use it quickly get it by using tianji.
|
This is a very common method in website analysis. You can use it quickly get it by using **Tianji**.
|
||||||
|
|
||||||
After you inject script code into your website, you just need add a `data-tianji-event` in dom attribute.
|
After you inject script code into your website, you just need add a `data-tianji-event` in dom attribute.
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user