Skip to content

Add ts declaration for @vue/cli-test-utils, Plugin API, Generator API #5324

Closed
@fangbinwei

Description

@fangbinwei

What problem does this feature solve?

I code by vscode, and these is no code intelliSense when coding vue-cli-plugin and plugin unit test.

If ts declarations are provided, it will be helpful. I'm maintaing some vue cli plugins for some times, it's just a pain point for me.

What does the proposed API look like?

for @vue/cli-test-utils, add declaration to cli-test-utils folder, like createTestProject.d.ts, vscode can finish code completion even in .js file.

for plugin, generator api, maybe like this?

import {GeneratorAPI} from '@vue/cli'
import {PluginAPI} from '@vue/cli-service'

or

import {GeneratorAPI, PluginAPI} from '@vue/cli-types'

export =  function (api: GeneratorAPI, options: any) {

}

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions