Skip to content

Instantly share code, notes, and snippets.

Last active Apr 17, 2020
What would you like to do?
Simple initial setup with Node, Typescript, Yarn and Vscode
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit:
"version": "0.2.0",
"configurations": [
"type": "node",
"request": "attach",
"protocol": "inspector",
"restart": true,
"name": "Debug",
"skipFiles": [
"outFiles": [

I recommend VSCode as main code editor.

Essential Extensions for VSCode

Setup a new project

yarn init -y
yarn tsc --init
yarn add typescript -D
yarn add express
yarn add @types/express -D
yarn add ts-node-dev -D
yarn add eslint -D

Setup ESLint

yarn eslint --init

My settings for ESLint

> To check syntax, find problems, and enforce code style
> JavaScript modules (import/export)
> None of these
> Does your project use TypeScript? **YES**
> Node (check this option and disable Browser)
> Use a popular style guide
> Standard!
> N (copy the line** informed and install with Yarn)

** The config that you've selected requires the following dependencies

yarn add -D @typescript-eslint/eslint-plugin@latest eslint-config-standard@latest eslint@>=6.2.2 eslint-plugin-import@>=2.18.0 eslint-plugin-node@>=9.1.0 eslint-plugin-promise@>=4.2.1 eslint-plugin-standard@>=4.0.0 @typescript-eslint/parser@latest

VSCode Settings

    "editor.formatOnSave": true,
    "editor.codeActionsOnSave": {
        "source.fixAll.eslint": true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment