Это видео недоступно.
Сожалеем об этом.

Unlock VS Code Efficiency with these Hacks

Поделиться
HTML-код
  • Опубликовано: 15 авг 2024
  • These VS code shortcuts will help step up your workflow!
    Bracket Pair Colorizer: marketplace.vi...
    ---
    Come and hangout, ask questions, suggest ideas, and meet some awesome people over in The Community: / discord
    I have a newsletter! www.kevinpowel...
    I've been working on some courses! Find out more: www.kevinpowel...
    ---
    My Code Editor: VS Code - code.visualstu...
    How my browser refreshes when I save: • How to automatically r...
    ---
    Support me on Patreon: / kevinpowell
    I'm on some other places on the internet too!
    If you'd like a behind the scenes and previews of what's coming up on my RUclips channel, make sure to follow me on Instagram and Twitter.
    Instagram: / kevinpowell.co
    Twitter: / kevinjpowell
    Codepen: codepen.io/kev...
    Github: github.com/kev...

Комментарии • 110

  • @KevinPowell
    @KevinPowell  4 года назад +12

    Are there any shortcuts that you use all the time that I didn't mention? Let me know what they are!

    • @kiprasmel
      @kiprasmel 4 года назад +2

      Hey Kevin - you seem like someone who'd enjoy vim - it allows you to minimize the amount of things you need to do with your mouse.
      Ever since I started using it and learnt a little, I now use it for lots of shortcuts, in a lot of programs, also as a browser extension and obviously in vscode:D Definitelly recommend; just know that the learning curve is quite steep, but I'm sure you can do it:D

    • @cyrep
      @cyrep 4 года назад +1

      ctrl + pageUp/Down
      ctrl + D

    • @Luxcium
      @Luxcium 4 года назад +4

      Kevin Powell cmd+shift+L select all of the same token as under the cursor

    • @aquaductape
      @aquaductape 4 года назад +1

      1. You can replicate tabbing in browser with setting this code in keybindings.json. Ctrl+Shift+p and type keyboard and then select Open Keyboard Shortcuts(JSON).
      {
      "key": "ctrl+tab",
      "command": "workbench.action.nextEditor"
      },
      {
      "key": "ctrl+shift+tab",
      "command": "workbench.action.previousEditor"
      },
      2. Install CSS Navigation extension, you can jump to class definitions from html to css. If your project includes sass and css and want definition to jump to sass, go to settings and under CSSNavigation, go to Active CSSFile Extension, then remove css from the list.
      3. Rename Symbol. Inside css file, put cursor over class name and press F2 which you can rename all occurrences of that class.

    • @digigoliath
      @digigoliath 4 года назад +1

      Duplicate & Delete Line

  • @abhinav.sharma
    @abhinav.sharma 4 года назад +23

    1. Alt + Z or ⌥ + Z → Word Wrap
    2. Ctrl + Shift + E or ⌘ + Z → Open Explorer
    3. Ctrl + P or ⌘ + P → Quickly get to a file
    4. Ctrl + Shift + T or ⌘ + Shift + T → Reopen closed tab
    5. Ctrl + W or ⌘ + W → Close current tab
    6. Alt + _Number of tab_ or ⌥ + _Number of tab_ → Quickly switch to a tab
    7. Alt + Click or ⌥ + Click → Multiple Cursors
    8. Ctrl + Alt + ↑/↓ or ⌘ + ⌥ + ↑/↓ → Lining up multiple cursors
    9. Alt + ↑/↓ or ⌥ + ↑/↓ → Switches the selected lines
    10. Ctrl + ~ or ⌘ + ~ → Opens the Terminal
    ♥ Keep Creating Kevin!!! ♥

    • @keaton718
      @keaton718 Год назад +1

      Thanks, now I can print it!

  • @burnblue
    @burnblue 4 года назад +22

    Alt Shift Down to duplicate the line instead of moving it.

  • @keaton718
    @keaton718 Год назад

    I knew about word wrap option and used to leave it on all the time, but I never thought about toggling it on and off only when needing to access long lines. That's a good tip.

  • @notrajanmali
    @notrajanmali 4 года назад +7

    One shortcut I really like is Ctrl/ Cmd + Page up and Ctrl/ Cmd + Page Down for toggling through tabs sequentially when you have multiple tabs open.
    Another setting, not a shortcut per se I make sure to turn on is formatOnSave, really saves me time from having to manually format my code.
    Another great video as always Kevin, really appreciated this one. Cheers!

  • @sherifsalah5563
    @sherifsalah5563 4 года назад +15

    Some of these shortcuts are awesome, thank you so much.
    Btw, you forgot to mention ctrl+d to select matching text through the whole file and do quick edit and replace (i cannot live without it).

  • @DaveDesSmith
    @DaveDesSmith 2 года назад +2

    For anyone seeing this in 2022. Bracket Pair Colourizer is now built into VSCode

  • @Noxxiee.3862
    @Noxxiee.3862 4 года назад +1

    When you are in the cmd + p menu (Mac), you can leave the marker on the file you want, press ctrl + return (on mac) at it will open it in a new pane. use cmd + a number(again on Mac) to navigate to a window.

  • @rashikkarmacharya8023
    @rashikkarmacharya8023 4 года назад +2

    pretty useful that! alt+shift+DOWN should be included to rapidly copy lines of repeating codes, just as important in my opinion. emmet makes it easier but still it has its uses.

  • @abhishekverma614
    @abhishekverma614 4 года назад

    I was here just for that multiple-cursor trick in VS which I have watched a lot in your tutorials...thanks a lot, sir...it is just a life savior for me

  • @cintron3d
    @cintron3d 4 года назад +3

    Ctrl + shift + t
    Thank you, thank you, thank you!
    I hadn't heard of that one before but whish I knew about it years ago lol. I'm always closing the wrong tab too.

  • @fury.turtle6790
    @fury.turtle6790 4 года назад

    1. toggle word wrap
    W : alt + z
    M : opt + z
    2. toggle the side bar
    W : ctrl + b
    M : cmd + b
    3. toggle file explorer
    W : ctrl + shift + e
    M : cmd + shift + e
    4. quick open a file
    W : ctrl + p
    M : cmd + p
    5. reopen a tab you just closed
    W : ctrl + shift + t
    M : cmd + shift + t
    6. close the active tab
    W : ctrl + w
    M : cmd + w
    7. go to a specific tab that is open
    W : alt + number
    M : ctrl + number(I think???)
    8. add cursor to lines above/below
    W : ctrl + alt + up/down
    M : cmd + option + up/down

    9. toggle the terminal
    W : ctrl + ~
    M : cmd + ~

  • @jeffborges101
    @jeffborges101 4 года назад +1

    Kevin your videos are amazing.
    I was learning bootstrap. But after watching a few of your videos on css
    I think it's better learn CSS with you.
    It will give me more flexibility in the front end.
    I will start your course tomorrow. Thank you

  • @fer86bd
    @fer86bd 4 года назад +1

    ctrl+shift+a comments the selected. And ctrl+tab swith between tabs (similar to alt+tab for windows)

  • @ronidey380
    @ronidey380 4 года назад +2

    Ctrl + shift + p (on windows)
    Now you would see a list containing almost every command available on VS code.

  • @admiralrohan
    @admiralrohan 3 года назад

    Searching for alt + 1 shortcut long time. Thank you.

  • @carladilisio4819
    @carladilisio4819 2 года назад

    Make sure you have active the multiple cursor. I just figured that out because It wasn't working and I inspected the program to see If I had to activate some shortcut extension XD

  • @soulfly1102
    @soulfly1102 4 года назад +1

    Hey Kevin, nice video. Would love to see how you organize your .sass files, especially the grid ones. It would be awesome if you can share. Keep up the good stuff.

    • @KevinPowell
      @KevinPowell  4 года назад +2

      Thanks for the suggestion :) - I keep changing how I approach my grids still. Once I find something that I'm most settled on I'll do a video on it :)

  • @rishabsharma5307
    @rishabsharma5307 4 года назад +1

    Make a video on flexbox layout not teaching flexbox but making complex layout using flexbox and grids. And it would be awesome if you make a series on it

  • @Luxcium
    @Luxcium 4 года назад

    Finally!!! (I am not a css person but I love your videos) and anything VSCode is amazing 😉

  • @gopalloharnew5948
    @gopalloharnew5948 2 года назад +1

    I don't think VS code need that much mouse movements ... because the keyborad shortcuts and easy keyborad navigation makes it almost mouse free !
    Tell me what do you feel about it \/

  • @ericervin2513
    @ericervin2513 3 года назад

    excellent vid also great channel. Subscribed Thank you!

  • @siriusgd4753
    @siriusgd4753 4 года назад

    Very helpful as usual Kevin. Thanks!

  • @fer86bd
    @fer86bd 4 года назад

    Its excelent!! it would save me so much time if watch it before, lol. But i still learn one new one. Thanks!!!

  • @digigoliath
    @digigoliath 4 года назад +1

    Awesome! I'm loving it. Thanks for the tips. Are we heading towards a great big cheatsheet? VS for coding fun!!

    • @KevinPowell
      @KevinPowell  4 года назад +1

      A big cheatsheet is a good idea, thanks!

  • @JaredMatthewSewell
    @JaredMatthewSewell 3 года назад

    Great video with very useful information. Thank you. Not sure if my MAC is different than others. It seems to be sometimes. On MY MAC, in order to add more cursors, I have to do alt+click.

  • @Knards
    @Knards 4 года назад +2

    On my VS Code multiple cursers is Alt-click not ctrl-click

    • @ortania
      @ortania 4 года назад +1

      In my too

    • @onesandzeroes
      @onesandzeroes 4 года назад

      @@ortania Mine as well. But I'm on Linux - maybe it's a Linux thing?

  • @ABMA79
    @ABMA79 3 года назад

    amazing and beneficial

  • @Steve-Richter
    @Steve-Richter 4 года назад +7

    CTRL + D - create additional cursor at next find location.

    • @ekimmike2002ify
      @ekimmike2002ify 3 года назад

      This is the one ive been looking for, thanks

  • @tomwolf6353
    @tomwolf6353 4 года назад +1

    Hi, could you make a video about using the proper html outline algorithm?

    • @KevinPowell
      @KevinPowell  4 года назад +1

      While I wish I could, the outline algorithm isn't actually implemented anywhere. It's an awesome idea that has no use sadly.... developer.mozilla.org/en-US/docs/Web/Guide/HTML/Using_HTML_sections_and_outlines

  • @siriusgd4753
    @siriusgd4753 4 года назад +2

    I see "Bracket Pair Colorizer 2". I'm assuming it's the same thing with fixes so that's the one I'm installing.

  • @lonelylosersclub8453
    @lonelylosersclub8453 2 года назад

    Does anybody know what he means by control click? Because I’m pressing control and clicking my pad and it’s not working

  • @thedacian123
    @thedacian123 3 года назад

    On Windows is alt+click not ctrl+click for placing the cursor in multipoe places

  • @chlouis-girardot
    @chlouis-girardot 4 года назад

    Ok ohh well... hmm.... THANKS KEVIN! You're the best!

  • @anandk_jha
    @anandk_jha 3 года назад +1

    "ctrl + right click" for multiple cursor is not working in my vs code, works perfectly fine in sublime

    • @BenjaminAster
      @BenjaminAster 3 года назад +1

      It's Alt+left click in VSCode.

    • @anandk_jha
      @anandk_jha 3 года назад +1

      @@BenjaminAster thanks a lot

  • @manishsahani4867
    @manishsahani4867 4 года назад +1

    Make a video on Skelton Screen with custom CSS

    • @KevinPowell
      @KevinPowell  4 года назад +1

      A few people have been asking for this lately, I'll look into it a bit more :)

    • @manishsahani4867
      @manishsahani4867 4 года назад +1

      @@KevinPowell please make a video.
      RUclips has some of the video regarding this topic but not clearly explained.

  • @Luxcium
    @Luxcium 4 года назад

    Bracket pair colorizer have a different version ‘2’ if you want

  • @marcelchaloupka
    @marcelchaloupka 4 года назад

    Maybe b is for browser

  • @mortkebab2849
    @mortkebab2849 4 года назад

    On my VS Code (Insiders edition) alt-z was bound to "toggle zen mode" so I remove that binding and attached it to "toggle word wrap."

  • @reviewex9226
    @reviewex9226 4 года назад

    god level

  • @castlemoyle
    @castlemoyle 4 года назад

    Just don't get too rambunctious using that CTRL-W close combination. If you do it once too often, you'll also close Code!

    • @KevinPowell
      @KevinPowell  4 года назад

      ctrl+q should quit code, not ctrl+w.... I'll have to test this, terrible oversight if it does close it!

    • @sadhlife
      @sadhlife 3 года назад

      @@KevinPowell it does close it

  • @christopherwilson9358
    @christopherwilson9358 4 года назад +1

    Ctrl + [ and Ctrl + ] indent and outdent a line for you

    • @fer86bd
      @fer86bd 4 года назад

      nice one!!! thanks

  • @jaynj908
    @jaynj908 4 года назад

    I am supriised they do let you detach the sidebar to another display

  • @techtips4019
    @techtips4019 4 года назад

    you are awesome

  • @malangope
    @malangope 4 года назад

    You didnt mention one of the best features of ctrl + p, which is you can search for something by just typing parts of the name. Like if you're looking for "index.html" you can just type inht and it will match INdex.HTml.

  • @Steve-Richter
    @Steve-Richter 4 года назад

    Can I collapse a region of html - example a nav or table section - then use down arrow somehow to move the entire section?

    • @KevinPowell
      @KevinPowell  4 года назад

      I think so? Be worth testing out

  • @ItsSunnyMonster
    @ItsSunnyMonster 3 года назад

    0:00 Hmm... I wonder what is that white window...
    OBS Obviously

  • @FranciL02
    @FranciL02 4 года назад

    To toggle to the terminal for Mac is ctrl + ~ and not cmd

    • @KevinPowell
      @KevinPowell  4 года назад

      Oh no! I went too fast there :(
      I always find it strange when things are bound to ctrl on a mac, it's so rare! I'll put a note in the description, thanks for letting me know.

    • @FranciL02
      @FranciL02 4 года назад

      @@KevinPowell np, always happy to help out

  • @joeldcanfield_spinhead
    @joeldcanfield_spinhead 4 года назад

    5:05 go to a specific open tab by #-if a Mac has Spaces, CTRL+n goes to Space n, but does nothing in VSC. dunno if the behavior is difference not using Spaces, but why would anyone not use Spaces on their Mac, eh?

    • @KevinPowell
      @KevinPowell  4 года назад

      I had trouble hunting this one down to be honest, since I'm on Windows. I had assumed it would be opt + n, since normally opt == alt on windows, but everything I saw had it as ctrl, which is a terrible key binding. I did see *a lot* of posts about how to change it to cmd + n though!

  • @lorezyra
    @lorezyra 3 года назад

    Why not use git? That way you can revert to the previously committed version should you accidently saved a file that should not have been saved.

  • @AH-cf9cv
    @AH-cf9cv 4 года назад

    O' u back thanks #kevin.

  • @carolmckay5152
    @carolmckay5152 4 года назад

    I use the extension Rainbow Brackets, not sure how this compares to Bracket Pair Colorizer.

    • @KevinPowell
      @KevinPowell  4 года назад

      Looks similar, but it hasn't been updated in 3 years now. Not sure that matters for something so simple though :)

    • @carolmckay5152
      @carolmckay5152 4 года назад

      @@KevinPowell Thanks for your response Kevin.

  • @songwright
    @songwright 4 года назад

    This is all great but how to you turn off the helpful hints that VS Code keeps shoving in my face when I'm trying to type something?

    • @YaroLord
      @YaroLord 3 года назад +1

      look for 'hover' in the settings and disable it

  • @syediqbalahmed3176
    @syediqbalahmed3176 4 года назад

    good

  • @3-dog-solution
    @3-dog-solution 4 года назад

    Love the on going tutorials, bit jealous that you've actually got 'VS Code' working though.
    Many haven't: including me, and despite watching many many vids on the subject; this error constantly gets in the way.
    "phpcs: Request workspace/configuration failed with message: Unable to locate phpcs. Please add phpcs to your global path or use composer dependency manager to install it in your project locally."
    Set the path, reinstalled and set 'composer', then individually set the path to 'composer'. Nothing works, and as I say that error message pops up every time you open a CSS file, really frustrating.
    Currently still using Notepad++, it works.
    Perhaps, (with your superb teaching skills), you could do a TUT on the pitfalls of getting this horrid program to work as prescribed - just a thought.
    Oft' to watch one of your other CSS lessons now, can't get enough of your laid teaching style: really learning shed-loads since finding you on u-Tube.
    Many thanks, ..Many thanks, ..

    • @KevinPowell
      @KevinPowell  4 года назад +1

      Interesting, I've never did anything. I just installed it and it worked.
      I'd suggest Atom or Sublime if you're having trouble with VS Code.
      Are you using PHP anywhere? Really strange that that pops up when you open a CSS file.

    • @3-dog-solution
      @3-dog-solution 4 года назад

      @@KevinPowell
      Hello my beloved mentor, (serious here: cos your teaching techniques are somewhat bloomin' brilliant.) Just wish that I could afford to pay you something for your time, but being retired and on the state pension does that: (it makes you broke.)
      PHP wise: I'm running the Laragon Server with personal home page version 7.(something) installed: been through the rest of the WIMP WAMP Servers with varying degrees of success. I'll mention here that VS Code didn't work with any of them either. Ended up with Laragon cos it flipping well works right out of the box, and no faffing about with missing DLLs either.
      (EasyPHP I'm looking at you here, what a pain that was to set-up.)
      Note to self: (don't get distracted.) As I say: I'm running Notepad++ at this end with no problems whatsoever, .. I just wish it had some of the real cool features that VS Code has to offer, but unfortunately (++) hasn't got them; even with various plugins installed.
      Can't win them all: many thanks for replying ..

  • @obsidianmd
    @obsidianmd 4 года назад

    6:26 control + alt + down/up when I do that my screen rotate is 180 degree working O.o

  • @mayureshs80
    @mayureshs80 4 года назад

    What vs code color theme and font is it in the video ?

    • @KevinPowell
      @KevinPowell  4 года назад +1

      I forget the font (I'm not on my computer right now and want to make sure I don't forget to reply), but the colour scheme is Atom One Dark

    • @mayureshs80
      @mayureshs80 4 года назад

      Kevin Powell thank you for prompt response. Please update on font if you can

    • @mayureshs80
      @mayureshs80 4 года назад

      Kevin Powell did you get a chance to look up the font ?

    • @KevinPowell
      @KevinPowell  4 года назад +1

      @@mayureshs80 haven't as I'm out of town for the weekend. I seem to think that I had changed it, and then went back to the default later on, which is Consolas

  • @myobjectivescoding
    @myobjectivescoding 4 года назад

    How do you get better at css and responsive design

    • @avneet12284
      @avneet12284 4 года назад +1

      By practice. Watch Kevin's old videos and watch his course on Scrimba. Watch Brad Traversy' videos and take Jonas Schmedtmann' Udemy course on advanced css

    • @KevinPowell
      @KevinPowell  4 года назад +1

      As avneet said, practice is key. The more you build, the more you learn.
      Start small, go over the fundamentals, understand them and keep on pushing all the time.

  • @ortania
    @ortania 4 года назад +3

    Great lectures!!!
    Ctrl+/ to add a comment. Works in all CSS/SCSS/JS/Html

    • @KevinPowell
      @KevinPowell  4 года назад +1

      Oh, how did I not include that, might be the one I use the most!

  • @gaafgeel6855
    @gaafgeel6855 4 года назад

    Isn't there some cheatsheet with all these things?

    • @KevinPowell
      @KevinPowell  4 года назад

      Yup, there are a few out there.

  • @ankitgupta9155
    @ankitgupta9155 4 года назад

    Hello sir , i have one query pls tell us how to install Python on vs code . I have already seen many videos but I am unable to understand. Your help will be greatful for me and others also.🙏🙏🙏🙏

    • @KevinPowell
      @KevinPowell  4 года назад

      I've never used Python so I don't think I'm the right person to help here.

    • @ankitgupta9155
      @ankitgupta9155 4 года назад

      @@KevinPowell oK sir , Thanks for Your reply and Your videos help me much in designing basically CSS and thanks for being here.

  • @FirdavsiWebDev
    @FirdavsiWebDev 4 года назад

    Why not atom or sublime?

    • @KevinPowell
      @KevinPowell  4 года назад

      I used to use Atom, but tried out VS Code based on someones recommendation and loved it. I prefer it's git integration over atom and a few other small things. I still think atom is great though.
      I never got into Sublime.