这几天写angularjs的拦截器时候发现$httpProvider.interceptors.push('authInterceptor');这一句一直报错,后来发现angularjs版本的问题,interceptors数组是1.3及以后的版本才开始用的,1.3之前的版本用的拦截器数组是responseInterceptors,而我那时候是下的angularjs种子程序,版本为v1.0.7,气死我了,于是版本更新到v1.6.6就好了
responseInterceptors和interceptors
最新推荐文章于 2024-06-06 17:45:26 发布