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

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

213 active golfers, 720 entries

Solutions by @skamgolf:
21
#29 - skamgolf / @skamgolf

11/05/2019 at 01:36AM

21
#>29 - skamgolf / @skamgolf

11/05/2019 at 01:37AM

22
#>65 - skamgolf / @skamgolf

11/05/2019 at 01:34AM

23
#>90 - skamgolf / @skamgolf

11/05/2019 at 01:33AM

24
#>109 - skamgolf / @skamgolf

11/05/2019 at 01:32AM

25
#>121 - skamgolf / @skamgolf

11/05/2019 at 01:30AM

26
#>134 - skamgolf / @skamgolf

11/05/2019 at 01:29AM

26
#>134 - skamgolf / @skamgolf

11/05/2019 at 02:14AM

27
#>146 - skamgolf / @skamgolf

11/05/2019 at 01:26AM

28
#>173 - skamgolf / @skamgolf

11/05/2019 at 01:25AM

29
#>188 - skamgolf / @skamgolf

11/05/2019 at 01:24AM