Stella inattivaStella inattivaStella inattivaStella inattivaStella inattiva

Visual Studio Code has so many extensions that it takes a long time to choose which one to use. Let me share with my favorites. Just a list with a brief descriptions.

Stella inattivaStella inattivaStella inattivaStella inattivaStella inattiva

Recently I found a solution to run a javascript to temporary apply changes on a web site.

I had 2 cases where I changed some stuff in 3rd party webpage. Of course it's a temporary change until the page is reloaded.

In one case I need to remove the class "hidden-print" because the print invoice do not print some info. I need that but the supplier never fix it.

Stella inattivaStella inattivaStella inattivaStella inattivaStella inattiva

I was playing with the linux history command and after some tries I was searching on internet and I found a good feature on Visual Studio Code for the integrated terminal.

VS Code has 2 features for:

  • Commands for Current session
  • Commands for Previous sessions
  • Visited Directories for Current session
  • Visited Directories for Previous sessions

 Finally a good, easy and pratics way to manage your comand history plus the new history for directory visited.

I binding my keys, I choosen CTRL + ALT + UP arrow for history commands and CTRL - ALT + LEFT arrow for directories.

Stella inattivaStella inattivaStella inattivaStella inattivaStella inattiva

Here how you can customize the key bindings in order to switch focus between editor and integrated terminal.

I have done it editing the file "data\user-data\User\keybindings.json" and adding the settings there. Just save and test it.

My binds in my italian keyboards:

CTRL + \ 

Switch focus between Editor and Terminal
The key backslash "\" in my keyboard is under the ESC key.

ALT + \ 

Open the Terminal if it's closed

Stella inattivaStella inattivaStella inattivaStella inattivaStella inattiva

When you use Visual Studio Code with SSH extension you can run from your linux command line the command "code" to edit your files. let me say it's fantastic, real useful. If you still using classic Terminal session with Putty or others, you will need a classic linux editor like nano. Well I often fall in a mitstake and write code in putty and viceversa.

Solution is to create a function () and name it "nano" and stored it in the .bashrc file.

Stella inattivaStella inattivaStella inattivaStella inattivaStella inattiva

This article contains how to customize the foreground, background and cursor color on VS Code Terminal.

Use different colors schema for each ssh remote helps to recognize them. Or maybe you want to change your local terminal colors.

We need to add/change the workbench setting inside the file settings.json.

Stella inattivaStella inattivaStella inattivaStella inattivaStella inattiva

One of my latest experience has been to show the correct date time to russian guys.

In order to manage the right local date for each country I have done the following 3 simple steps:

  1. Store the date in GMT format (Greenwich Mean Time)
  2. Declare the momentJS in my webpage
  3. Use the momentJS function to convert the date

Browser will do a right conversion

 

Valutazione attuale: 3 / 5

Stella attivaStella attivaStella attivaStella inattivaStella inattiva

If a word starts with # or @ or other special char like $, your autocomplete search fails? Here a workaround to fix it.

Stella inattivaStella inattivaStella inattivaStella inattivaStella inattiva

Some useful snippet for the database mysql.

Stella inattivaStella inattivaStella inattivaStella inattivaStella inattiva

Some of tips and tricks for this great editor.

Stella inattivaStella inattivaStella inattivaStella inattivaStella inattiva

Some useful Javascript Snippets 

Stella inattivaStella inattivaStella inattivaStella inattivaStella inattiva

Alcuni comandi utili da utilizzare in un server MSSQL.

Stella inattivaStella inattivaStella inattivaStella inattivaStella inattiva

Image to have a table like the following and you need to get the max value of COL2 for each COL1.

Stella inattivaStella inattivaStella inattivaStella inattivaStella inattiva

Some useful snippets for the Hypertext Preprocessor or better knows as PHP.

Stella inattivaStella inattivaStella inattivaStella inattivaStella inattiva

This page contains some jquery code snippets. I wrote them day by day during developping, so they are not well organized but for sure they are useful.

Sottocategorie

vb.netVB.Net
php logo mediumPHP Scripts
sqlDatabases sql scripts and more
javascriptJavascript scripts
vscodePHP Scripts