@vue-solana/nuxt 4.0.0-rc.0 → 4.0.0-rc.1

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/dist/module.mjs +8 -7
  2. package/package.json +2 -2
package/dist/module.mjs CHANGED
@@ -89,15 +89,13 @@ const module$1 = defineNuxtModule({
89
89
  nuxt: "^3.0.0 || ^4.0.0"
90
90
  }
91
91
  },
92
- defaults: MODULE_DEFAULTS,
93
92
  setup(options, nuxt) {
94
93
  const resolver = createResolver(import.meta.url);
95
94
  const publicConfig = nuxt.options.runtimeConfig.public;
96
95
  publicConfig.solana = toPublicSolanaConfig(
97
96
  mergeSolanaSources({
98
97
  publicSolana: isPlainObject(publicConfig.solana) ? publicConfig.solana : {},
99
- options,
100
- configuredSolana: isPlainObject(nuxt.options.solana) ? nuxt.options.solana ?? {} : {}
98
+ options
101
99
  })
102
100
  );
103
101
  const vueDist = resolveVueDist();
@@ -124,17 +122,20 @@ const module$1 = defineNuxtModule({
124
122
  });
125
123
  function mergeSolanaSources({
126
124
  publicSolana,
127
- options,
128
- configuredSolana
125
+ options
129
126
  }) {
130
127
  const merged = { ...publicSolana };
131
128
  for (const [key, value] of Object.entries(options)) {
132
- const untouchedDefault = key in MODULE_DEFAULTS && Object.is(value, MODULE_DEFAULTS[key]) && !Object.hasOwn(configuredSolana, key);
133
- if (untouchedDefault && Object.hasOwn(publicSolana, key)) {
129
+ if (value === void 0) {
134
130
  continue;
135
131
  }
136
132
  merged[key] = value;
137
133
  }
134
+ for (const [key, value] of Object.entries(MODULE_DEFAULTS)) {
135
+ if (merged[key] === void 0) {
136
+ merged[key] = value;
137
+ }
138
+ }
138
139
  return merged;
139
140
  }
140
141
  function isPlainObject(value) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vue-solana/nuxt",
3
- "version": "4.0.0-rc.0",
3
+ "version": "4.0.0-rc.1",
4
4
  "description": "Nuxt module for Solana applications.",
5
5
  "license": "MIT",
6
6
  "keywords": [
@@ -45,7 +45,7 @@
45
45
  "access": "public"
46
46
  },
47
47
  "dependencies": {
48
- "@vue-solana/vue": "4.0.0-rc.0"
48
+ "@vue-solana/vue": "4.0.0-rc.1"
49
49
  },
50
50
  "peerDependencies": {
51
51
  "nuxt": "^3.0.0 || ^4.0.0"