Skip to content

Commit

Permalink
format readme
Browse files Browse the repository at this point in the history
  • Loading branch information
tiagoefmoraes committed Jan 30, 2024
1 parent f75e1ad commit 2c09d0a
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Surface Catalogue

This is mostly a prototype, meant to validate a few ideas to have something similar to
https://storybook.js.org/ for [Surface](https://github.com/msaraiva/surface).
<https://storybook.js.org/> for [Surface](https://github.com/msaraiva/surface).

## Installation

Expand Down Expand Up @@ -179,21 +179,21 @@ end

Run the server with:

```
```bash
mix dev
```

or using `iex`:

```
```bash
iex -S mix dev
```

You can now access the catalogue at [localhost:4000](http://localhost:4000/catalogue/).

If you need, you can also start the server using a different port:

```
```bash
PORT=4444 iex -S mix dev
```

Expand Down
4 changes: 3 additions & 1 deletion lib/surface/catalogue/server.ex
Original file line number Diff line number Diff line change
Expand Up @@ -87,10 +87,12 @@ defmodule Surface.Catalogue.Server do
Task.start(fn ->
children = [
{Phoenix.PubSub, [name: __MODULE__.PubSub, adapter: Phoenix.PubSub.PG2]},
__MODULE__.Endpoint
{__MODULE__.Endpoint, [log_access_url: false]}
]

{:ok, _} = Supervisor.start_link(children, strategy: :one_for_one)
require Logger
Logger.info("Access Surface Catalogue at #{__MODULE__.Endpoint.url()}/catalogue")
Process.sleep(:infinity)
end)
end
Expand Down

0 comments on commit 2c09d0a

Please sign in to comment.