Search Unity

  1. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Question Is there better way in renaming class name in VS Code?

Discussion in 'Code Editors & IDEs' started by Pandazole, Oct 6, 2023.

  1. Pandazole

    Pandazole

    Joined:
    Sep 23, 2019
    Posts:
    23
    Hi!

    Currently the best way that is working for may is first to rename the class inside VS Code Editor, then renaming the script file inside Unity editor (Renaming it inside vs code will mess up the assembly connections and other scripts references)

    Is there a way similar to VS 2022 like the"CTRL+R", "CTRL+R" functionality? Which renames the class name, the file and refresh the unity project files.

    Thanks!
     
  2. CodeSmile

    CodeSmile

    Joined:
    Apr 10, 2014
    Posts:
    5,066
  3. Pandazole

    Pandazole

    Joined:
    Sep 23, 2019
    Posts:
    23
    Thanks for your reply, I will check it soon. I’ve been using vs community within the last 6-7 years, but currently I would prefer vs code over it though :)
     
  4. CodeSmile

    CodeSmile

    Joined:
    Apr 10, 2014
    Posts:
    5,066
    I use Rider. Itis bot free but more than worth it due to its extremely well done Unity integration including asset browser, search in assets, auto-updating dependencies in asmdef, it knows all the Unity event methods aaand so much more.
     
    FaithlessOne and Pandazole like this.
  5. plazmaberst

    plazmaberst

    Joined:
    May 24, 2020
    Posts:
    2