CORS issue with Vue.js

后端 未结 5 734
鱼传尺愫
鱼传尺愫 2020-12-03 03:37

I\'m using:

  • Vue 2.0.3
  • vue-router 2.0.1
  • vuex 0.8.2
  • vue-resource 0.7.0

And after trying to login to my page when using

5条回答
  •  心在旅途
    2020-12-03 04:06

    Greater possibility is that CORS is not enabled on the IIS. This can be enabled by modifying the web.config file in the application root folder in IIS as follows:

    
    
    
       
             
               
             
       
    
    
    
    

    Note: This method will allow anyone to reach the API endpoint and hence shouldn't be adopted on a production environment but only on a development environment.

提交回复
热议问题