Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Indentation is wrong when using Regex #302

@tian-yi

Description

@tian-yi

Working though the book "Programming Phoenix", in one code example:

def player_id(video) do
    ~r/^.*(?:youtu.be\/|v\/|e\/|u\/\w+\/|embed\/|v=)(?<id>[^#\&\?]*).*/
    |> Regex.named_captures(video.url)
    |> get_in(["id"])
  end

But when I type this snippet in, it shows like this
screen shot 2016-01-02 at 21 31 23

OS: OS X El Capitan
Emacs version: 24.5.1 (Using spacemacs setup)
Elixir-mode: 20151211.412

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions