Real Vim ninjas count every keystroke - do you?

Pick a challenge, fire up Vim, and show us what you got.

Changelog, Rules & FAQ, updates: @vimgolf, RSS.

Your VimGolf key: please sign in

$ gem install vimgolf
$ vimgolf setup
$ vimgolf put 5d7259d2c0248a000c157f9f

Add string initializers to an enum

Change Typescript enum so that it has string initializers.

Start file
const enum TestkitType {
  vanilla,
  unidriver,
  protractor,
  puppeteer,
  unknown,
}
End file
const enum TestkitType {
  vanilla = 'VANILLA',
  unidriver = 'UNIDRIVER',
  protractor = 'PROTRACTOR',
  puppeteer = 'PUPPETEER',
  unknown = 'UNKNOWN',
}

View Diff

2,6c2,6
<   vanilla,
<   unidriver,
<   protractor,
<   puppeteer,
<   unknown,
---
>   vanilla = 'VANILLA',
>   unidriver = 'UNIDRIVER',
>   protractor = 'PROTRACTOR',
>   puppeteer = 'PUPPETEER',
>   unknown = 'UNKNOWN',

Solutions by @tefetic:

Unlock 8 remaining solutions by signing in and submitting your own entry
Created by: @argshook

258 active golfers, 872 entries

Solutions by @tefetic:
21
#40 - Tefe / @tefetic

01/31/2020 at 10:03PM

22
#>86 - Tefe / @tefetic

01/31/2020 at 10:02PM

23
#>115 - Tefe / @tefetic

01/31/2020 at 10:01PM

24
#>138 - Tefe / @tefetic

01/31/2020 at 09:57PM

25
#>152 - Tefe / @tefetic

01/31/2020 at 09:55PM

26
#>169 - Tefe / @tefetic

01/31/2020 at 09:54PM

27
#>189 - Tefe / @tefetic

01/31/2020 at 09:53PM

28
#>213 - Tefe / @tefetic

01/31/2020 at 09:52PM