I want to store some data in the form of an object and have this data read by a number of components within my React application. For simplicity I'm not using Redux or any other kind of global state management.

Is it more performant to use:

```
const myData = window.myData;

```

Or:

```
const myData = localStorage.getItem('myData');

```