We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent e35f2b8 commit fe10b06Copy full SHA for fe10b06
client/app/components/DynamicComponent.jsx
@@ -6,8 +6,8 @@ const componentsRegistry = new Map();
6
const activeInstances = new Set();
7
8
export function registerComponent(name, component) {
9
- if (isString(name) && (name !== '')) {
10
- componentsRegistry[name] = isFunction(component) ? component : null;
+ if (isString(name) && name !== '') {
+ componentsRegistry.set(name, isFunction(component) ? component : null);
11
// Refresh active DynamicComponent instances which use this component
12
activeInstances.forEach((dynamicComponent) => {
13
if (dynamicComponent.props.name === name) {
0 commit comments