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

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

259 active golfers, 873 entries

Solutions by @leo28356948:
21
#22 - leo / @leo28356948

10/17/2019 at 08:25AM

22
#>78 - leo / @leo28356948

10/17/2019 at 08:24AM

23
#>110 - leo / @leo28356948

10/17/2019 at 08:23AM

24
#>135 - leo / @leo28356948

10/17/2019 at 08:21AM

25
#>151 - leo / @leo28356948

10/17/2019 at 08:21AM

26
#>164 - leo / @leo28356948

10/17/2019 at 08:18AM

27
#>179 - leo / @leo28356948

10/17/2019 at 08:17AM

28
#>206 - leo / @leo28356948

10/17/2019 at 08:14AM

29
#>227 - leo / @leo28356948

10/17/2019 at 08:12AM

30
#>234 - leo / @leo28356948

10/17/2019 at 08:08AM

31
#>237 - leo / @leo28356948

10/17/2019 at 08:06AM

36
#>247 - leo / @leo28356948

10/17/2019 at 08:04AM