vuetify-nuxt-module 0.10.0 → 0.10.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.
package/dist/module.d.mts CHANGED
@@ -397,7 +397,7 @@ interface ModuleOptions extends VuetifyModuleOptions {
397
397
  interface ModuleHooks {
398
398
  'vuetify:registerModule': (registerModule: (config: InlineModuleOptions) => void) => HookResult;
399
399
  }
400
- interface RuntimeModuleHooks {
400
+ interface ModuleRuntimeHooks {
401
401
  'vuetify:configuration': (options: {
402
402
  isDev: boolean;
403
403
  vuetifyOptions: VuetifyOptions;
@@ -443,4 +443,4 @@ declare module '@nuxt/schema' {
443
443
  }
444
444
  }
445
445
 
446
- export { type ComponentName, type Components, type DateAdapter, type DateOptions, type DirectiveName, type Directives, type ExternalVuetifyOptions, type FontAwesomeSvgIconSet, type FontIconSet, type IconFontName, type IconSetName, type IconsOptions, type InlineModuleOptions, type JSSVGIconSet, type LabComponentName, type LabComponents, type MOptions, type ModuleHooks, type ModuleOptions, type RuntimeModuleHooks, type SSRClientHints, type SSRClientHintsConfiguration, type UnoCCSMdiIconSet, type VOptions, type VuetifyLocale, type VuetifyModuleOptions, _default as default };
446
+ export { type ComponentName, type Components, type DateAdapter, type DateOptions, type DirectiveName, type Directives, type ExternalVuetifyOptions, type FontAwesomeSvgIconSet, type FontIconSet, type IconFontName, type IconSetName, type IconsOptions, type InlineModuleOptions, type JSSVGIconSet, type LabComponentName, type LabComponents, type MOptions, type ModuleHooks, type ModuleOptions, type ModuleRuntimeHooks, type SSRClientHints, type SSRClientHintsConfiguration, type UnoCCSMdiIconSet, type VOptions, type VuetifyLocale, type VuetifyModuleOptions, _default as default };
package/dist/module.d.ts CHANGED
@@ -397,7 +397,7 @@ interface ModuleOptions extends VuetifyModuleOptions {
397
397
  interface ModuleHooks {
398
398
  'vuetify:registerModule': (registerModule: (config: InlineModuleOptions) => void) => HookResult;
399
399
  }
400
- interface RuntimeModuleHooks {
400
+ interface ModuleRuntimeHooks {
401
401
  'vuetify:configuration': (options: {
402
402
  isDev: boolean;
403
403
  vuetifyOptions: VuetifyOptions;
@@ -443,4 +443,4 @@ declare module '@nuxt/schema' {
443
443
  }
444
444
  }
445
445
 
446
- export { type ComponentName, type Components, type DateAdapter, type DateOptions, type DirectiveName, type Directives, type ExternalVuetifyOptions, type FontAwesomeSvgIconSet, type FontIconSet, type IconFontName, type IconSetName, type IconsOptions, type InlineModuleOptions, type JSSVGIconSet, type LabComponentName, type LabComponents, type MOptions, type ModuleHooks, type ModuleOptions, type RuntimeModuleHooks, type SSRClientHints, type SSRClientHintsConfiguration, type UnoCCSMdiIconSet, type VOptions, type VuetifyLocale, type VuetifyModuleOptions, _default as default };
446
+ export { type ComponentName, type Components, type DateAdapter, type DateOptions, type DirectiveName, type Directives, type ExternalVuetifyOptions, type FontAwesomeSvgIconSet, type FontIconSet, type IconFontName, type IconSetName, type IconsOptions, type InlineModuleOptions, type JSSVGIconSet, type LabComponentName, type LabComponents, type MOptions, type ModuleHooks, type ModuleOptions, type ModuleRuntimeHooks, type SSRClientHints, type SSRClientHintsConfiguration, type UnoCCSMdiIconSet, type VOptions, type VuetifyLocale, type VuetifyModuleOptions, _default as default };
package/dist/module.json CHANGED
@@ -5,5 +5,5 @@
5
5
  "nuxt": "^3.6.5",
6
6
  "bridge": false
7
7
  },
8
- "version": "0.10.0"
8
+ "version": "0.10.1"
9
9
  }
package/dist/module.mjs CHANGED
@@ -14,7 +14,7 @@ import { parseQuery, parseURL } from 'ufo';
14
14
  import destr from 'destr';
15
15
  import { transformAssetUrls } from 'vite-plugin-vuetify';
16
16
 
17
- const version = "0.10.0";
17
+ const version = "0.10.1";
18
18
 
19
19
  const VIRTUAL_VUETIFY_CONFIGURATION = "virtual:vuetify-configuration";
20
20
  const RESOLVED_VIRTUAL_VUETIFY_CONFIGURATION = `/@nuxt-vuetify-configuration/${VIRTUAL_VUETIFY_CONFIGURATION.slice("virtual:".length)}`;
@@ -1249,31 +1249,34 @@ dependsOn.push('vuetify:client-hints:server:plugin')
1249
1249
  }
1250
1250
  }
1251
1251
  addPluginTemplate({
1252
- filename: "vuetify-nuxt-plugin.ts",
1252
+ filename: "vuetify-nuxt-plugin.mjs",
1253
1253
  write: false,
1254
1254
  getContents() {
1255
1255
  return `
1256
- import type { createVuetify } from 'vuetify'
1257
- import { configureVuetify } from 'vuetify-nuxt-module/dist/runtime/plugins/config'
1258
1256
  import { defineNuxtPlugin } from '#imports'
1259
- import type { Plugin } from '#app'
1257
+ import { isDev, vuetifyConfiguration } from 'virtual:vuetify-configuration'
1258
+ import { createVuetify } from 'vuetify'
1260
1259
 
1261
1260
  const dependsOn = ${JSON.stringify(dependsOn)}
1262
1261
  ${addHttpClientHintsPlugin}
1263
1262
 
1264
- const plugin: Plugin<{
1265
- vuetify: ReturnType<typeof createVuetify>
1266
- }> = defineNuxtPlugin({
1267
- name: 'vuetify:configuration:plugin',
1263
+ export default defineNuxtPlugin({
1264
+ name: 'vuetify:nuxt:plugin',
1268
1265
  order: 25,
1269
1266
  dependsOn,
1270
1267
  parallel: true,
1271
- async setup() {
1272
- await configureVuetify()
1268
+ async setup(nuxtApp) {
1269
+ const vuetifyOptions = vuetifyConfiguration()
1270
+ await nuxtApp.hooks.callHook('vuetify:configuration', { isDev, vuetifyOptions })
1271
+ await nuxtApp.hooks.callHook('vuetify:before-create', { isDev, vuetifyOptions })
1272
+ const vuetify = createVuetify(vuetifyOptions)
1273
+ nuxtApp.vueApp.use(vuetify)
1274
+ nuxtApp.provide('vuetify', vuetify)
1275
+ await nuxtApp.hooks.callHook('vuetify:ready', vuetify)
1276
+ if (process.client)
1277
+ isDev && console.log('Vuetify 3 initialized', vuetify)
1273
1278
  },
1274
1279
  })
1275
-
1276
- export default plugin
1277
1280
  `;
1278
1281
  }
1279
1282
  });
package/dist/types.d.mts CHANGED
@@ -1,8 +1,8 @@
1
1
 
2
- import type { ModuleOptions, ModuleHooks, RuntimeModuleHooks } from './module.js'
2
+ import type { ModuleOptions, ModuleHooks, ModuleRuntimeHooks } from './module.js'
3
3
 
4
4
  declare module '#app' {
5
- interface RuntimeNuxtHooks extends RuntimeModuleHooks {}
5
+ interface RuntimeNuxtHooks extends ModuleRuntimeHooks {}
6
6
  }
7
7
 
8
8
  declare module '@nuxt/schema' {
@@ -18,4 +18,4 @@ declare module 'nuxt/schema' {
18
18
  }
19
19
 
20
20
 
21
- export type { ComponentName, Components, DateAdapter, DateOptions, DirectiveName, Directives, ExternalVuetifyOptions, FontAwesomeSvgIconSet, FontIconSet, IconFontName, IconSetName, IconsOptions, InlineModuleOptions, JSSVGIconSet, LabComponentName, LabComponents, MOptions, ModuleHooks, ModuleOptions, RuntimeModuleHooks, SSRClientHints, SSRClientHintsConfiguration, UnoCCSMdiIconSet, VOptions, VuetifyLocale, VuetifyModuleOptions, default } from './module.js'
21
+ export type { ComponentName, Components, DateAdapter, DateOptions, DirectiveName, Directives, ExternalVuetifyOptions, FontAwesomeSvgIconSet, FontIconSet, IconFontName, IconSetName, IconsOptions, InlineModuleOptions, JSSVGIconSet, LabComponentName, LabComponents, MOptions, ModuleHooks, ModuleOptions, ModuleRuntimeHooks, SSRClientHints, SSRClientHintsConfiguration, UnoCCSMdiIconSet, VOptions, VuetifyLocale, VuetifyModuleOptions, default } from './module.js'
package/dist/types.d.ts CHANGED
@@ -1,8 +1,8 @@
1
1
 
2
- import type { ModuleOptions, ModuleHooks, RuntimeModuleHooks } from './module'
2
+ import type { ModuleOptions, ModuleHooks, ModuleRuntimeHooks } from './module'
3
3
 
4
4
  declare module '#app' {
5
- interface RuntimeNuxtHooks extends RuntimeModuleHooks {}
5
+ interface RuntimeNuxtHooks extends ModuleRuntimeHooks {}
6
6
  }
7
7
 
8
8
  declare module '@nuxt/schema' {
@@ -18,4 +18,4 @@ declare module 'nuxt/schema' {
18
18
  }
19
19
 
20
20
 
21
- export type { ComponentName, Components, DateAdapter, DateOptions, DirectiveName, Directives, ExternalVuetifyOptions, FontAwesomeSvgIconSet, FontIconSet, IconFontName, IconSetName, IconsOptions, InlineModuleOptions, JSSVGIconSet, LabComponentName, LabComponents, MOptions, ModuleHooks, ModuleOptions, RuntimeModuleHooks, SSRClientHints, SSRClientHintsConfiguration, UnoCCSMdiIconSet, VOptions, VuetifyLocale, VuetifyModuleOptions, default } from './module'
21
+ export type { ComponentName, Components, DateAdapter, DateOptions, DirectiveName, Directives, ExternalVuetifyOptions, FontAwesomeSvgIconSet, FontIconSet, IconFontName, IconSetName, IconsOptions, InlineModuleOptions, JSSVGIconSet, LabComponentName, LabComponents, MOptions, ModuleHooks, ModuleOptions, ModuleRuntimeHooks, SSRClientHints, SSRClientHintsConfiguration, UnoCCSMdiIconSet, VOptions, VuetifyLocale, VuetifyModuleOptions, default } from './module'
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "vuetify-nuxt-module",
3
3
  "type": "module",
4
- "version": "0.10.0",
4
+ "version": "0.10.1",
5
5
  "packageManager": "pnpm@8.14.1",
6
6
  "description": "Zero-Config Nuxt Module for Vuetify",
7
7
  "author": "userquin <userquin@gmail.com>",
@@ -137,4 +137,4 @@
137
137
  "installDependencies": false,
138
138
  "startCommand": "node .stackblitz.js && pnpm install && nr prepack && nr dev:prepare && nr dev"
139
139
  }
140
- }
140
+ }
@@ -1 +0,0 @@
1
- export declare function configureVuetify(): Promise<void>;
@@ -1,16 +0,0 @@
1
- import { createVuetify } from "vuetify";
2
- import { isDev, vuetifyConfiguration } from "virtual:vuetify-configuration";
3
- import { useNuxtApp } from "#imports";
4
- export async function configureVuetify() {
5
- const nuxtApp = useNuxtApp();
6
- const vuetifyOptions = vuetifyConfiguration();
7
- await nuxtApp.hooks.callHook("vuetify:configuration", { isDev, vuetifyOptions });
8
- await nuxtApp.hooks.callHook("vuetify:before-create", { isDev, vuetifyOptions });
9
- const vuetify = createVuetify(vuetifyOptions);
10
- nuxtApp.vueApp.use(vuetify);
11
- nuxtApp.provide("vuetify", vuetify);
12
- await nuxtApp.hooks.callHook("vuetify:ready", vuetify);
13
- if (process.client) {
14
- isDev && console.log("Vuetify 3 initialized", vuetify);
15
- }
16
- }