Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/rspack-contrib/rsbuild-plugin-google-analytics
An Rsbuild plugin to setup Google Analytics in your website.
https://github.com/rspack-contrib/rsbuild-plugin-google-analytics
plugin rsbuild rspack
Last synced: 3 months ago
JSON representation
An Rsbuild plugin to setup Google Analytics in your website.
- Host: GitHub
- URL: https://github.com/rspack-contrib/rsbuild-plugin-google-analytics
- Owner: rspack-contrib
- License: mit
- Created: 2024-03-24T02:24:28.000Z (3 months ago)
- Default Branch: main
- Last Pushed: 2024-03-24T02:56:40.000Z (3 months ago)
- Last Synced: 2024-03-24T03:20:57.025Z (3 months ago)
- Topics: plugin, rsbuild, rspack
- Language: TypeScript
- Homepage:
- Size: 0 Bytes
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Lists
- awesome-rspack - rsbuild-plugin-google-analytics
README
# rsbuild-plugin-google-analytics
An Rsbuild plugin to setup Google Analytics in your website.
## Usage
Install:
```bash
npm add rsbuild-plugin-google-analytics -D
```Add plugin to your `rsbuild.config.ts`:
```ts
// rsbuild.config.ts
import { pluginGoogleAnalytics } from 'rsbuild-plugin-google-analytics';export default {
plugins: [
pluginGoogleAnalytics({
// replace this with your Google tag ID
// see: https://support.google.com/analytics/answer/9539598?hl=en
id: 'G-xxxxxxxxxx',
}),
],
};
```## Options
Here are the available options:
| Name | Type | Description | Defaults |
| ---- | -------- | ------------- | ----------- |
| id | `string` | Google tag ID | `undefined` |## License
[MIT](./LICENSE).