2
私はVisual Studioのコミュニティ2015のアップデートを使用しています。3. 私は、このリソースごとにCORSを有効にしようと忙しい: https://docs.asp.net/en/latest/security/cors.htmlservices.AddCorsため(「呼び出しは、次の方法の間で曖昧である」)
- 私は新しい.NET Core Web APIプロジェクトのバージョン1.0.0を作成しました。 Startup.csで
- は、
ConfigureServices()
下私が追加:services.AddCors()
- しかし、
project.json
に次の依存関係を追加した後:私は削除することを確認することができますThe call is ambiguous between the following methods or properties: 'Microsoft.Extensions.DependencyInjection.CorsServiceCollectionExtensions.AddCors(Microsoft.Extensions.DependencyInjection.IServiceCollection)' and 'Microsoft.Extensions.DependencyInjection.CorsServiceCollectionExtensions.AddCors(Microsoft.Extensions.DependencyInjection.IServiceCollection)'
: "Microsoft.AspNet.Cors": "6.0.0-rc1-final"
、私は次のエラーを得ましたその依存関係がエラーを解決します。どんな指針も大変ありがとうございます。
他のAspNetライブラリはありますが、まだこのエラーがあります –
ありがとう非常に良い^^^ –