UNPKG

can-globals

Version:

This module provides a dependency injection container. Modules may define a key and specify a default value (which can be static, cached lazy, or dynamic lazy), but other code can set and reset the value as needed. There is also an event system, for alert

26 lines (15 loc) 1.45 kB
# can-globals [![Join our Slack](https://img.shields.io/badge/slack-join%20chat-611f69.svg)](https://www.bitovi.com/community/slack?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) [![Join our Discourse](https://img.shields.io/discourse/https/forums.bitovi.com/posts.svg)](https://forums.bitovi.com/?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](https://github.com/canjs/can-globals/blob/master/LICENSE) [![npm version](https://badge.fury.io/js/can-globals.svg)](https://www.npmjs.com/package/can-globals) [![Build Status](https://travis-ci.org/canjs/can-globals.svg?branch=master)](https://travis-ci.org/canjs/can-globals) [![Greenkeeper badge](https://badges.greenkeeper.io/canjs/can-globals.svg)](https://greenkeeper.io/) An environment agnostic container for global variables. Useful for testing and server-side rendering (SSR), typically used internally by CanJS. ## Documentation Read the [API docs on CanJS.com](https://canjs.com/doc/can-globals.html). ## Changelog See the [latest releases on GitHub](https://github.com/canjs/can-globals/releases). ## Contributing The [contribution guide](https://github.com/canjs/can-globals/blob/master/CONTRIBUTING.md) has information on getting help, reporting bugs, developing locally, and more. ## License [MIT](https://github.com/canjs/can-globals/blob/master/LICENSE)