<!-- /docs/redux/store.md -->

# 🧠 Redux Store (store.js)

Zentrale Konfiguration des globalen Redux-Stores für die Anwendung.  
Er verwaltet Zustand für Daten aus Webservices, der Datenbank und UI-Status.

---

## 🔌 Verwendung

```js
import { Provider } from "react-redux";
import { store } from "../redux/store";

<Provider store={store}>
  <App />
</Provider>
```

---

## 🔁 Struktur

Der Store besteht aus drei Bereichen:

### 1. `database`

- `poiMarkers`, `addPoi`, `poiLayerVisible`
- `gisLinesFromDatabase`, `polylineLayerVisible`
- `readPoiMarkersStore`, `priorityConfig`, `locationDevicesFromDB`

### 2. `webservice`

- `gisStationsStaticDistrict`, `gisStationsStatusDistrict`, `gisSystemStatic`
- `gisStationsMeasurements`, `gisLinesStatusFromWebservice`, `userRights`

### 3. `ui / interaktiv`

- `mapLayers`, `selectedDevice`, `selectedPoi`, `selectedArea`
- `lineVisibility`, `zoomTrigger`, `urlParameter`, `polylineContextMenu`
- `polylineEventsDisabled`, `addPoiOnPolyline`

---

## ⚙️ Einrichtung

```js
export const store = configureStore({
  reducer: {
    selectedDevice: selectedDeviceReducer,
    poiMarkers: poiMarkersReducer,
    ...
  }
});
```

---

## 📁 Pfad

```bash
/redux/store.js
```