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

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

216 active golfers, 724 entries

Solutions by @tkarandi:
21
#25 - Tamás Kárándi / @tkarandi

10/19/2019 at 01:41PM

22
#>64 - Tamás Kárándi / @tkarandi

10/19/2019 at 01:40PM

23
#>90 - Tamás Kárándi / @tkarandi

10/19/2019 at 01:38PM

24
#>109 - Tamás Kárándi / @tkarandi

10/19/2019 at 01:37PM

25
#>122 - Tamás Kárándi / @tkarandi

10/19/2019 at 01:35PM

26
#>134 - Tamás Kárándi / @tkarandi

10/19/2019 at 01:22PM

27
#>148 - Tamás Kárándi / @tkarandi

10/19/2019 at 01:16PM