doudang1890 2019-04-14 19:35
浏览 134

如何在Laravel 5.7中使用Vue.js文件(不是CDN)?

I have almost completed my Admin Panel in laravel 5.7, however needed to use VueJS for some component. I am aware Vue comes by default with laravel, and also saw the app.js file under resources/js directory in laravel.

However, is there a possibility where I can use Vue.js file that I have downloaded, and import it with the script tag? I tried by placing the script and vue code in the blade file itself, but it conflicts with the laravel {{ blade_syntax }}.

Is there a systematic way to not use VueCLI, or CDN, but the plain vuejs file? Need I copy the vuejs file i downloaded inside Laravel Project? If so, where should I place the file?

Or am I going wrong somewhere?

Any suggestion would be highly appreciated.

  • 写回答

1条回答 默认 最新

  • dsqve08622 2019-04-14 19:47
    关注

    you need to place the vue.js or any js,css script to the public folder of your laravel projects. in your laravel projects look for public place your vue.js file anywhere in this folder say you put it to js folder now to inculde it you use asset ('js/vue.js') on your blade.php file. thats it.

    评论

报告相同问题?

悬赏问题

  • ¥15 如何在scanpy上做差异基因和通路富集?
  • ¥20 关于#硬件工程#的问题,请各位专家解答!
  • ¥15 关于#matlab#的问题:期望的系统闭环传递函数为G(s)=wn^2/s^2+2¢wn+wn^2阻尼系数¢=0.707,使系统具有较小的超调量
  • ¥15 FLUENT如何实现在堆积颗粒的上表面加载高斯热源
  • ¥30 截图中的mathematics程序转换成matlab
  • ¥15 动力学代码报错,维度不匹配
  • ¥15 Power query添加列问题
  • ¥50 Kubernetes&Fission&Eleasticsearch
  • ¥15 報錯:Person is not mapped,如何解決?
  • ¥15 c++头文件不能识别CDialog