Omnisharp-vscode: ASP.NET Core auto import does not work

Created on 29 Sep 2019  路  3Comments  路  Source: OmniSharp/omnisharp-vscode

With this code

using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc.RazorPages;

namespace ContactManager.Pages
{
    [AllowAnonymous]
    public class IndexModel : PageModel
    {
        public void OnGet()
        {

        }
    }
}

I typed [AllowAnonymous] but it did not auto import Microsoft.AspNetCore.Authorization.

Is this intentional or should this work?

Editor-IntelliSense Feature Request Triaged

Most helpful comment

use "Ctrl+." to trigger "import", it doesn't work if your input method not in English(en)(on my Ubuntu)

All 3 comments

use "Ctrl+." to trigger "import", it doesn't work if your input method not in English(en)(on my Ubuntu)

Auto imports would be amazing to have! Cycling through auto suggestions feels great (waiting and pressing ctrl + . in this case does not)

Closing as a duplicate of #3730

Was this page helpful?
0 / 5 - 0 ratings

Related issues

mattwoberts picture mattwoberts  路  3Comments

IdeoG picture IdeoG  路  3Comments

ZeldaZocker picture ZeldaZocker  路  3Comments

gregg-miskelly picture gregg-miskelly  路  3Comments

ghost picture ghost  路  3Comments