UNPKG

react-avatar

Version:

Universal React avatar component makes it possible to generate avatars based on user information.

22 lines (21 loc) 571 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.default = void 0; class InternalState { constructor() { this.sourcePointer = 0; this.active = true; this.fetch = null; } isActive() { let state = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; // Internal state has been reset => we received new props if (state.internal !== this) return false; if (!this.fetch) return false; if (this.active !== true) return false; return true; } } exports.default = InternalState;