Skip to content

copy-formatted-for-elm-repl: copy selected code into clipboard formatted for pasting into repl #167

@stepheneb

Description

@stepheneb

I'd like to be able to copy selected multiline Elm code into the clipboard and be able to paste it into the elm repl formatted to be able to be successfully evaluated.

I'm curious whether this is possible ... and how hard it would be -- or maybe it already exists??

For example this code copied and pasted into the elm repl generates an error:

type alias Option =
    { id : Int
    , name : Stri

Adding \ at the end of each line except for the last allows the repl to evaluate it successfully:

type alias Option = \
    { id : Int \
    , name : String \
    }

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions