# @tanglemedia/directus-extension-bundle-page-views

A Directus extension bundle that adds a page views module into your Directus project. The package will install the following:

- A collection named tngl_page_views
- A Page Views Analytics dashboard which shows the number of page views, device usage, unique vistors, etc.

It automatically sets the following:

- Creates a new role called Analytics. If the Analytics role already exist, it will not create a new one.
- Anaytics role will have CREATE and UPDATE permissions to the tngl_page_views

## Requirements

- Directus >= 10.10.1
- Node >= 18.x.x

You should have the following extensions installed:

- directus-extension-display-link

## Install

1. Add the following variables to your Directus env file:
   - `SITE_BASE_URL` (Base URL of the site you want to track the page views)

2. `npm i @tanglemedia/directus-extension-bundle-page-views`

3. `npx directus bootstrap` to update your database and restart directus
