mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-11 08:33:53 +00:00
feat: add intellisense for loaders
This commit is contained in:
parent
6cb16f41cf
commit
7f51c8a133
@ -119,9 +119,9 @@ ${nuxt.options.experimental.componentIslands ? islandType : ''}
|
|||||||
interface _GlobalComponents {
|
interface _GlobalComponents {
|
||||||
${componentTypes.map(([pascalName, type]) => ` '${pascalName}': ${type}`).join('\n')}
|
${componentTypes.map(([pascalName, type]) => ` '${pascalName}': ${type}`).join('\n')}
|
||||||
${componentTypes.map(([pascalName, type]) => ` 'Lazy${pascalName}': ${type}`).join('\n')}
|
${componentTypes.map(([pascalName, type]) => ` 'Lazy${pascalName}': ${type}`).join('\n')}
|
||||||
${componentTypes.map(([pascalName, type]) => ` 'LazyIdle${pascalName}': ${type}`).join('\n')}
|
${componentTypes.map(([pascalName, type]) => ` 'LazyIdle${pascalName}': ${type} & DefineComponent<{loader?: IdleRequestOptions}>`).join('\n')}
|
||||||
${componentTypes.map(([pascalName, type]) => ` 'LazyVisible${pascalName}': ${type}`).join('\n')}
|
${componentTypes.map(([pascalName, type]) => ` 'LazyVisible${pascalName}': ${type} & DefineComponent<{loader?: Partial<IntersectionObserverInit>}>`).join('\n')}
|
||||||
${componentTypes.map(([pascalName, type]) => ` 'LazyEvent${pascalName}': ${type}`).join('\n')}
|
${componentTypes.map(([pascalName, type]) => ` 'LazyEvent${pascalName}': ${type} & DefineComponent<{loader?: Array<keyof HTMLElementEventMap>}>`).join('\n')}
|
||||||
}
|
}
|
||||||
|
|
||||||
declare module '@vue/runtime-core' {
|
declare module '@vue/runtime-core' {
|
||||||
@ -138,9 +138,9 @@ declare module 'vue' {
|
|||||||
|
|
||||||
${componentTypes.map(([pascalName, type]) => `export const ${pascalName}: ${type}`).join('\n')}
|
${componentTypes.map(([pascalName, type]) => `export const ${pascalName}: ${type}`).join('\n')}
|
||||||
${componentTypes.map(([pascalName, type]) => `export const Lazy${pascalName}: ${type}`).join('\n')}
|
${componentTypes.map(([pascalName, type]) => `export const Lazy${pascalName}: ${type}`).join('\n')}
|
||||||
${componentTypes.map(([pascalName, type]) => `export const LazyIdle${pascalName}: ${type}`).join('\n')}
|
${componentTypes.map(([pascalName, type]) => `export const LazyIdle${pascalName}: ${type} & DefineComponent<{loader?: IdleRequestOptions}>`).join('\n')}
|
||||||
${componentTypes.map(([pascalName, type]) => `export const LazyVisible${pascalName}: ${type}`).join('\n')}
|
${componentTypes.map(([pascalName, type]) => `export const LazyVisible${pascalName}: ${type} & DefineComponent<{loader?: Partial<IntersectionObserverInit>}>`).join('\n')}
|
||||||
${componentTypes.map(([pascalName, type]) => `export const LazyEvent${pascalName}: ${type}`).join('\n')}
|
${componentTypes.map(([pascalName, type]) => `export const LazyEvent${pascalName}: ${type} & DefineComponent<{loader?: Array<keyof HTMLElementEventMap>}>`).join('\n')}
|
||||||
|
|
||||||
export const componentNames: string[]
|
export const componentNames: string[]
|
||||||
`
|
`
|
||||||
|
Loading…
Reference in New Issue
Block a user