There is a sentence in the documentation for upgrading to laravel 5.4 that I don’t understand. Documentation: http://laravelacademy.org/pos...
In order to be compatible with Laravel 5.4 and the Axios JavaScript library, Laravel Passport has released version 2.0.0. If you upgrade from Laravel 5.3 and use the preset Passport Vue component, you need to ensure that the Axios library is in the form of axios. The application is globally valid.
I don’t understand the above sentence, what should I do?
小伙看你根骨奇佳,潛力無限,來學(xué)PHP伐。
This is described in the official documentation
If you are upgrading from Laravel 5.3 and using the pre-built Passport Vue components, you should make sure the Axios library is globally available to your application as axios.
Actually, if your application is upgraded from Laravel 5.3 and you use the built-in Passport
Vue組件的話,應(yīng)該確保Axios
類庫是全局可用的,而使用它的時(shí)候必須是使用axios
作為類庫的名字。說白了就是在頁面中直接引入(比如使用script src=xxx)axios
這個(gè)類庫就可以了,如果沒有使用到Passport
Vue component, then this can be ignored.