### createLocalVue Source: https://vue-test-utils.vuejs.org Creates a local Vue constructor that can be used to install plugins without affecting the global Vue constructor. ```APIDOC ## createLocalVue ### Description Creates a local Vue constructor that can be used to install plugins without affecting the global Vue constructor. ### Method `createLocalVue() ### Request Example ```javascript import { createLocalVue } from '@vue/test-utils' const localVue = createLocalVue() ``` ### Response #### Success Response (Vue Constructor) - **Vue Constructor** - A local Vue constructor. ``` -------------------------------- ### mount Source: https://vue-test-utils.vuejs.org Mounts a Vue component, returning a Wrapper object. ```APIDOC ## mount ### Description Mounts a Vue component, returning a Wrapper object. ### Method `mount(Component, options?) ### Parameters #### Path Parameters - **Component** (Vue Component Constructor) - The component to mount. - **options** (Object) - Optional mounting options. ### Request Example ```javascript import { mount } from '@vue/test-utils' import MyComponent from '@/components/MyComponent.vue' const wrapper = mount(MyComponent, { propsData: { msg: 'Hello' } }) ``` ### Response #### Success Response (Wrapper) - **Wrapper** - An object with methods to interact with the mounted component. ``` -------------------------------- ### render Source: https://vue-test-utils.vuejs.org Renders a Vue component to static HTML, returning a Wrapper object. ```APIDOC ## render ### Description Renders a Vue component to static HTML, returning a Wrapper object. ### Method `render(Component, options?) ### Parameters #### Path Parameters - **Component** (Vue Component Constructor) - The component to render. - **options** (Object) - Optional mounting options. ### Request Example ```javascript import { render } from '@vue/test-utils' import MyComponent from '@/components/MyComponent.vue' const wrapper = render(MyComponent) ``` ### Response #### Success Response (Wrapper) - **Wrapper** - An object with methods to interact with the rendered component's static HTML. ``` -------------------------------- ### createWrapper Source: https://vue-test-utils.vuejs.org Creates a Wrapper instance for a given Vue instance. ```APIDOC ## createWrapper ### Description Creates a Wrapper instance for a given Vue instance. ### Method `createWrapper(instance, options?) ### Parameters #### Path Parameters - **instance** (Vue Instance) - The Vue instance to create a wrapper for. - **options** (Object) - Optional wrapper options. ### Request Example ```javascript import { createWrapper } from '@vue/test-utils' const MyComponent = { template: '
Hello
' } const wrapper = createWrapper(new MyComponent()) ``` ### Response #### Success Response (Wrapper) - **Wrapper** - A Wrapper instance for the provided Vue instance. ``` -------------------------------- ### renderToString Source: https://vue-test-utils.vuejs.org Renders a Vue component to a string of static HTML. ```APIDOC ## renderToString ### Description Renders a Vue component to a string of static HTML. ### Method `renderToString(Component, options?) ### Parameters #### Path Parameters - **Component** (Vue Component Constructor) - The component to render. - **options** (Object) - Optional mounting options. ### Request Example ```javascript import { renderToString } from '@vue/test-utils' import MyComponent from '@/components/MyComponent.vue' const html = renderToString(MyComponent) ``` ### Response #### Success Response (String) - **String** - The rendered static HTML of the component. ``` -------------------------------- ### shallowMount Source: https://vue-test-utils.vuejs.org Shallow mounts a Vue component, returning a Wrapper object. Child components are stubbed. ```APIDOC ## shallowMount ### Description Shallow mounts a Vue component, returning a Wrapper object. Child components are stubbed. ### Method `shallowMount(Component, options?) ### Parameters #### Path Parameters - **Component** (Vue Component Constructor) - The component to shallow mount. - **options** (Object) - Optional mounting options. ### Request Example ```javascript import { shallowMount } from '@vue/test-utils' import MyComponent from '@/components/MyComponent.vue' const wrapper = shallowMount(MyComponent) ``` ### Response #### Success Response (Wrapper) - **Wrapper** - An object with methods to interact with the shallow mounted component. ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.