Skip to content

Latest commit

History

30 Commits

Folders and files

NameName
Last commit message
Last commit date

Repository files navigation

concerto Build StatusHex.pmHex.pm

file-based routing library for elixir

Installation

Concerto is available in Hex and can be installed as:

  1. Add concerto your list of dependencies in mix.exs:

    def deps do [{:concerto, "~> 0.1.0"}] end

Usage

Given the following directory structure

.
├── lib
│ └── my_router.ex
└── web
├── GET.exs
└── users
└── @user
├── GET.exs
└── POST.exs

a router can be contstructed with the following:

defmoduleMyRouterdouseConcerto,root: "web",ext: ".exs",methods: ["GET","POST","PUT","DELETE","PATCH"],module_prefix: MyApp.Webend

API

match(method, path)

resolve(name, params)

resolve_module(name)

About

file-based routing library for elixir

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages