- Go into VSCode
- Install typescript
npm i typescript
for local ORnpm i -g typescript
for global - Run either
node_modules/.bin/tsc --init
for local installation ortsc --init
for global - Open the generated file
tsconfig.json
and pressCTRL+F
- Make sure to tick the regex filter for search on the far right of the search input (third icon)
- Pase that regex
\s* \/\* .* \*\/
- Replace by "nothing"
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
type Events = { | |
hook_1: string[]; | |
hook_2: number; | |
}; | |
const { addFilter, applyFilters } = new Filter<Events>(); | |
addFilter('hook_1', callback) | |
// ^ autocomplete on event names | |
// ^ static analysis on callback functions based on the specific event |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git branch -m old_branch new_branch # Rename branch locally | |
git push origin :old_branch # Delete the old branch | |
git push --set-upstream origin new_branch # Push the new branch, set local branch to track the new remote |