To start your Phoenix server:
- Install dependencies with
mix deps.get
- Create and migrate your database with
mix ecto.create && mix ecto.migrate
- Install Node.js dependencies with
cd assets && npm install
- Start Phoenix endpoint with
mix phx.server
Now you can visit localhost:4000
from your browser.
Ready to run in production? Please check our deployment guides.
- Official website: http://www.phoenixframework.org/
- Guides: http://phoenixframework.org/docs/overview
- Docs: https://hexdocs.pm/phoenix
- Mailing list: http://groups.google.com/group/phoenix-talk
- Source: https://github.com/phoenixframework/phoenix
query {
users(sortBy: "money", limit: 3) {
id
username
money
revenueRate
}
}
mutation {
createUser(username: "somebody") {
user {
username
id
}
}
}
{"CurrentUserId": "cced5bf9-a2cf-49a3-9278-ffce7a7db27a"}
query {
viewer {
username
money
revenueRate
expenseRate
}
}
query {
purchases {
type
name
cost
codeRate
revenueRate
expenseRate
}
}
mutation {
purchase(purchase: {type: "employee", name: "dev_intern"}) {
user {
username
employees {
hacker
}
}
}
}
mutation {
release {
user {
username
revenueRate
money
}
}
}