Check out example codes for "how to access the dictionary from another script in unity". It will help you in understanding the concepts better.

Code Example 1

if (Input.GetButtonDown("Reload"))         {             remainingClips = GameObject.FindGameObjectWithTag("InventoryController").GetComponent<InventoryClass>().playerAmmo[weaponType];             if (remainingClips > 0)             {                 Reload();             }

Learn ReactJs, React Native from akashmittal.com