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 @agorilladriving:

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

213 active golfers, 720 entries

Solutions by @agorilladriving:
21
#15 - blub / @agorilladriving

09/17/2019 at 01:57PM

23
#>85 - blub / @agorilladriving

09/17/2019 at 01:57PM

24
#>104 - blub / @agorilladriving

09/17/2019 at 01:56PM

25
#>118 - blub / @agorilladriving

09/17/2019 at 01:55PM

26
#>127 - blub / @agorilladriving

09/17/2019 at 01:53PM

27
#>145 - blub / @agorilladriving

09/17/2019 at 01:52PM

28
#>167 - blub / @agorilladriving

09/17/2019 at 01:45PM

30
#>194 - blub / @agorilladriving

09/17/2019 at 01:42PM

31
#>195 - blub / @agorilladriving

09/17/2019 at 11:06AM