I have the following element in .blade (with the intention of interacting with vue not with laravel):
<div id="app">
{{ message }}
</div>
To try to activate vue:
window.Vue = require('vue');
var app = new Vue({
el: '#app',
data: {
seen: true
}
})
And I get the following error from laravel:
Use of undefined constant message - assumed 'message' (this will throw an error in a future version of PHP) (View: C: \ xampp \ htdocs \ laravel \ Game \ resources \ views \ home.blade.php)
This error is due to the syntax of the blade {{ message }}
, well I can not think how to combine .blade with vue, apparently laravel offers support for this, but I could not figure out how it works.
The question is:
How to use vue.js in a .blade view of a large application?