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

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

258 active golfers, 872 entries

Solutions by @mutemeat:
21
#32 - mogitate / @mutemeat

11/14/2019 at 03:25PM

21
#>32 - mogitate / @mutemeat

11/14/2019 at 03:26PM

22
#>81 - mogitate / @mutemeat

11/14/2019 at 03:24PM

23
#>112 - mogitate / @mutemeat

11/14/2019 at 03:18PM

23
#>112 - mogitate / @mutemeat

11/14/2019 at 03:19PM

23
#>112 - mogitate / @mutemeat

11/14/2019 at 03:23PM

24
#>136 - mogitate / @mutemeat

11/14/2019 at 03:16PM

25
#>151 - mogitate / @mutemeat

11/14/2019 at 03:12PM

26
#>166 - mogitate / @mutemeat

11/14/2019 at 03:05PM