| Tweetovi |
|
Matt Bierner
@mattbierner
|
19 h |
|
Today's @code command: Fold All
Fold all the elements in a file to see a minimal outline. Unfold individual elements as needed or use the 'Unfold All' command to expand everything again
#code2020 pic.twitter.com/u6AFSzzUQP
|
||
|
|
||
|
Matt Bierner
@mattbierner
|
2. velj |
|
Today's @code extension: Sort lines (tyriar.sort-lines)
Sort selected lines of text in a number of different ways. You can even remove duplicates!
marketplace.visualstudio.com/items?itemName…
#code2020 pic.twitter.com/lBxZILi2Qd
|
||
|
|
||
|
Matt Bierner
@mattbierner
|
1. velj |
|
Today's @code setting: editor.tokenColorCustomizations
If you're an advanced VS Code user, you can fully tweak your theme with editor.tokenColorCustomizations. Change color of all comments for example or of specific JavaScript keywords
code.visualstudio.com/docs/getstarte…
#code2020 pic.twitter.com/ZsEWW63aLI
|
||
|
|
||
|
Matt Bierner
@mattbierner
|
31. sij |
|
Today's @code tip: extensions view search filters
Use special @ queries in VS Code's extension view to discover new extensions and manage your existing ones
code.visualstudio.com/docs/editor/ex…
#code2020 pic.twitter.com/l9QGkhTIiI
|
||
|
|
||
|
Matt Bierner
@mattbierner
|
30. sij |
|
Today's @code tip: hover peeks
While hovering over a symbol, VS Code shows its documentation and type info. You can also quickly preview the symbol's definition with ctrl (hold cmd on Mac)
#code2020 pic.twitter.com/Wz9ATO7DqC
|
||
|
|
||
|
Matt Bierner
@mattbierner
|
29. sij |
|
They have a distraction-free mode that you can try out: jetbrains.com/help/webstorm/…
|
||
|
|
||
|
Matt Bierner
@mattbierner
|
29. sij |
|
I should note that there's also a built-in 'Transform to Uppercase' command that does the same thing. This is mainly a fun example of what snippets can do
|
||
|
|
||
|
Matt Bierner
@mattbierner
|
29. sij |
|
Good point. Yes zen mode supports all the editor grid layout features from non zen mode VS Code (although centering only works if you have a single editor)
|
||
|
|
||
|
Matt Bierner
@mattbierner
|
29. sij |
|
A bonus @code tip for today: use this snippet keybinding to quickly uppercase selected text
{
"key": "ctrl+k ctrl+u",
"command": "editor.action.insertSnippet",
"args": {
"snippet": "${TM_SELECTED_TEXT/(.*)/${1:/upcase}/}"
}
} pic.twitter.com/5FcyOHMves
|
||
|
|
||
|
Matt Bierner
@mattbierner
|
29. sij |
|
Today's @code tip: column/box selection
Hold ctrl+shift while making a selection to create a column/box selection. VS Code creates a cursor at the end of each line so you can quickly edit blocks of text
#code2020 pic.twitter.com/cMLfAy2fLg
|
||
|
|
||
|
Matt Bierner
@mattbierner
|
28. sij |
|
Today's @code keybinding: toggle explorer
Quickly switch to focus the explorer, even if it's hidden
Windows/Linux: ctrl shift E
Mac: ⌘ shift E
#code2020 pic.twitter.com/rNzwaNJJOz
|
||
|
|
||
|
Matt Bierner
@mattbierner
|
27. sij |
|
Today's @code command: toggle zen mode
Zen mode helps you focus on your code by hiding other parts of the VS Code UI. That doesn't mean you can't still access the command palette, terminal, or the explorer however using keyboard shortcuts!
#code2020 pic.twitter.com/uZ9v3H165i
|
||
|
|
||
|
Matt Bierner
@mattbierner
|
27. sij |
|
The video shows it working with node so please file an issue if it doesn't work
|
||
|
|
||
|
Matt Bierner
@mattbierner
|
26. sij |
|
Today's @code tip: snippet keybindings
Create keybindings that insert specific snippets
code.visualstudio.com/docs/editor/us…
#code2020 pic.twitter.com/qEYGqTdm4A
|
||
|
|
||
|
Matt Bierner
@mattbierner
|
25. sij |
|
Today's @code setting: javascript.suggest.completeFunctionCalls
When accepting a suggestion for a #JavaScript function, fills in the parameters. Use tab to move through args to complete the call
Also works for #Typescript with typescript.suggest.completeFunctionCalls
#code2020 pic.twitter.com/PLieRy93wb
|
||
|
|
||
|
Matt Bierner
@mattbierner
|
24. sij |
|
If you prefer your daily @code tips on YouTube, I've created a new #code2020 channel for them!
youtube.com/channel/UCyYh-…
|
||
|
|
||
|
Matt Bierner
@mattbierner
|
24. sij |
|
Today's @code refactoring: extract constant
Extract the currently selected expression to a local variable.
Works out of the box for #JavaScript and #Typescript. Extensions can add support for other languages too!
#code2020 pic.twitter.com/6vvpEN2vjo
|
||
|
|
||
|
Matt Bierner
@mattbierner
|
24. sij |
|
💥 Count down your remaining seconds with the newly updated minutes-to-midnight nodejs library 💥
npmjs.com/package/minute…
Thanks @roblourens for the reminder!
|
||
|
|
||
|
Matt Bierner
@mattbierner
|
23. sij |
|
Also wtf @BulletinAtomic? The clock was using whole minutes for 60 years and when I come along and write a library it you start going half minutes and now third minutes? What's next, sqrt 2 minutes?
|
||
|
|
||
|
Matt Bierner
@mattbierner
|
23. sij |
|
Every time you start a new @typescript project without enabling strict mode, it advances one second toward armageddon...
|
||
|
|
||