@diosmosis opened this Pull Request on January 19th 2022 Member

Description:

Stores are singletons that can fetch data upon construction. This is helpful since it means components that use them don't have to manually initiate the fetch. However doing it this way can mean a lot of unneeded AJAX requests. The lazyInitSingleton function initializes a singleton upon first use so we only issue the AJAX requests when a store is used, without requiring components manually initialize them.

This is used in some of the sites manager PRs and some upcoming tag manager PRs.

Review

This Pull Request was closed on January 19th 2022
Powered by GitHub Issue Mirror