# localConfig

Source: https://developers.inkdrop.app/states/local-config

An [app state](https://developers.inkdrop.app/guides/flux-architecture) of [the local config](https://developers.inkdrop.app/modules/config) currently loaded.
This state allows you to use the config values of [`config.json`](https://docs.inkdrop.app/reference/user-data-directory) in your react components.
It immediately reflects to the state whenever the config file is changed.
The data structure is same as the file content.

---

## Accessing the State

The `localConfig` state provides information about the currently loaded local configuration settings of the application.

To get the `localConfig` state manually:

```js
const { localConfig } = env.store.getState()
```

Connect the state with your React component:

```js
  import { useSelector } from 'react-redux'
  const selector = ({ localConfig }) => localConfig
  const MyComponent = props => {
    const localConfig = useSelector(selector)
    // render
  }
```
