• This repository has been archived on 22/Jan/2024
  • Stars
    star
    197
  • Rank 191,481 (Top 4 %)
  • Language
    JavaScript
  • Created about 4 years ago
  • Updated 4 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

A plugin to add support for using Vue components within Livewire.

Livewire VueJS Support Plugin

If you are using VueJS AND Livewire on the same page, this plugin is required.

Additionally, it allows you to use Vue components within your Livewire components.

Livewire Version Support

Livewire Version Vue Plugin Version
1.x 0.2.x
2.x 0.3.x

Installation

CDN

Include the CDN asset after @livewireScripts or <livewire:scripts> in your app's HTML:

    ...
    @livewireScripts
    <script src="https://cdn.jsdelivr.net/gh/livewire/[email protected]/dist/livewire-vue.js"></script>
</body>

NPM

Install the package from NPM.

npm install livewire-vue --save-dev

Import the package in your bundle:

import 'livewire-vue'
// Or.
require('livewire-vue')

App.js

Please make sure you load vue in a way required for this plugin to work as expected.

import Vue from 'vue'
import 'livewire-vue'

window.Vue = Vue //this is important! Do not use require('vue')