Skip to content

Instantly share code, notes, and snippets.

Avatar
👾
Consulting at Klarna

Klas Mellbourn Mellbourn

👾
Consulting at Klarna
View GitHub Profile
@Mellbourn
Mellbourn / klas-mellbourn.code-profile
Created May 6, 2022
My Visual Studio Code Settings Profile
View klas-mellbourn.code-profile
{"settings":"{\"settings\":\"{\\n \\\"[css]\\\": {\\n \\\"editor.defaultFormatter\\\": \\\"esbenp.prettier-vscode\\\"\\n },\\n \\\"[javascript][typescript][typescriptreact]\\\": {\\n \\\"editor.defaultFormatter\\\": \\\"esbenp.prettier-vscode\\\"\\n },\\n \\\"[json][jsonc]\\\": {\\n \\\"editor.defaultFormatter\\\": \\\"vscode.json-language-features\\\"\\n },\\n \\\"[less]\\\": {\\n \\\"editor.defaultFormatter\\\": \\\"esbenp.prettier-vscode\\\"\\n },\\n \\\"[markdown]\\\": {\\n \\\"files.trimTrailingWhitespace\\\": false\\n },\\n \\\"[scss]\\\": {\\n \\\"editor.defaultFormatter\\\": \\\"esbenp.prettier-vscode\\\"\\n },\\n \\\"audioCues.onDebugBreak\\\": \\\"on\\\",\\n \\\"css.lint.boxModel\\\": \\\"warning\\\",\\n \\\"css.lint.duplicateProperties\\\": \\\"warning\\\",\\n \\\"css.lint.float\\\": \\\"warning\\\",\\n \\\"css.lint.idSelector\\\": \\\"warning\\\",\\n \\\"css.lint.ieHack\\\": \\\"warning\\\",\\n \\\"css.lint.importStatement\\\": \\\"warning\\\",\\n \\\"css.lint
@Mellbourn
Mellbourn / profiles.json
Last active Mar 27, 2021
Windows terminal settings
View profiles.json
// To view the default settings, hold "alt" while clicking on the "Settings" button.
// For documentation on these settings, see: https://aka.ms/terminal-documentation
{
"$schema": "https://aka.ms/terminal-profiles-schema",
"defaultProfile": "{80107621-7b78-4e6a-8ea4-ab3bf7d1c805}",
"profiles": [
{
"guid": "{80107621-7b78-4e6a-8ea4-ab3bf7d1c805}",
"name": "tmux",
"commandline": "wsl.exe tmux attach -t base || tmux new -s base",
View typeScriptEnumThoughts.ts
const UP = "Up";
// problem: cannot use constant UP in enum declaration
// problem: generated JavaScript looks like crap
enum mixedEnum {
up = "Up",
one = 1
}
const mixupEnum: mixedEnum = mixedEnum.up;
// problem: cannot assign using string "Up"
// const mixupEnumFail: mixedEnum = UP;
View bd3d4befe38185704bf0fc875e9deed6|configuration.json
{"contents":{"editor":{"minimap":{"maxColumn":100},"rulers":[100]},"search":{"exclude":{"**/node_modules":true,"**/yarn.lock":true}},"cSpell":{"words":["Checkmark","alphanum","estore","externalid","healthcheck","healthchecks","merchantid","mockdate","paybutton","testid","yourhost"]},"[json]":{"editor.formatOnSave":true},"launch":{"version":"0.2.0","configurations":[{"name":"vscode-jest-tests","type":"node","request":"launch","address":"localhost","stopOnEntry":false,"runtimeExecutable":null,"env":{},"runtimeArgs":[],"args":["./node_modules/.bin/jest","--runInBand","--no-cache","--color","--watch"],"console":"integratedTerminal","cwd":"${workspaceFolder}/services/orders"},{"name":"Launch service","type":"node","request":"launch","runtimeExecutable":"yarn","env":{},"runtimeArgs":["start:dev"],"port":9235,"console":"integratedTerminal","cwd":"${workspaceFolder}/services/orders/"},{"name":"Attach to service","type":"node","request":"attach","stopOnEntry":false,"port":9235},{"name":"Service unit test","type":"node
@Mellbourn
Mellbourn / boxstarterDevBox.ps1
Last active May 6, 2022
Boxstarter script for Windows
View boxstarterDevBox.ps1
Set-WindowsExplorerOptions -EnableShowHiddenFilesFoldersDrives -EnableShowFileExtensions -EnableShowFullPathInTitleBar
#windows 8
#Set-StartScreenOptions -EnableBootToDesktop -EnableDesktopBackgroundOnStart
#upgrade PowerShell
iex "& { $(irm https://aka.ms/install-powershell.ps1) } -UseMSI"
#Enable-MicrosoftUpdate
Enable-RemoteDesktop
#Install-WindowsUpdate -Full -acceptEula