@hortonstudio/main 1.2.21 → 1.2.22

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.js +6 -2
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -1,4 +1,4 @@
1
- // Version: 1.2.21
1
+ // Version: 1.2.22
2
2
 
3
3
  const API_NAME = 'hsmain';
4
4
 
@@ -109,6 +109,10 @@ const initializeHsMain = async () => {
109
109
 
110
110
  const readyCallbacks = [];
111
111
 
112
+ // Initialize persistent config storage first, preserving any existing configs
113
+ const existingConfigs = window[API_NAME]?._persistentConfigs || {};
114
+ console.log('🏗️ Initializing main API - existing persistent configs:', existingConfigs);
115
+
112
116
  window[API_NAME] = {
113
117
  scripts,
114
118
  modules: {},
@@ -116,7 +120,7 @@ const initializeHsMain = async () => {
116
120
  load: loadModule,
117
121
  loaded: false,
118
122
  // Persistent config storage
119
- _persistentConfigs: {},
123
+ _persistentConfigs: existingConfigs,
120
124
  push(...items) {
121
125
  for (const [moduleName, callback] of items) {
122
126
  if (typeof callback === 'function') {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hortonstudio/main",
3
- "version": "1.2.21",
3
+ "version": "1.2.22",
4
4
  "description": "Animation and utility library for client websites",
5
5
  "main": "index.js",
6
6
  "type": "module",