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 5dd7ed687a0c210006a6820f

Refactor typescript arrow function type

Make arrow function type less verbose and easier to read

Start file
export const playground: (
  object?: Partial<PlaygroundSection>,
) => PlaygroundSection = config =>
  baseSection({
    type: SectionType.Playground,
    ...config,
  });
End file
export const playground = (
  config?: Partial<PlaygroundSection>,
): PlaygroundSection =>
  baseSection({
    type: SectionType.Playground,
    ...config,
  });

View Diff

1,3c1,3
< export const playground: (
<   object?: Partial<PlaygroundSection>,
< ) => PlaygroundSection = config =>
---
> export const playground = (
>   config?: Partial<PlaygroundSection>,
> ): PlaygroundSection =>

Solutions by @pikjes2:

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

60 active golfers, 272 entries

Solutions by @pikjes2:
20
#22 - pikjes / @pikjes2

03/21/2021 at 03:38PM

21
#>25 - pikjes / @pikjes2

03/21/2021 at 03:36PM

23
#>34 - pikjes / @pikjes2

03/21/2021 at 03:35PM

25
#>35 - pikjes / @pikjes2

03/21/2021 at 03:32PM

26
#>37 - pikjes / @pikjes2

03/21/2021 at 03:32PM

28
#>42 - pikjes / @pikjes2

03/21/2021 at 03:30PM

29
#>48 - pikjes / @pikjes2

03/21/2021 at 03:29PM