A simple example showing how to generate live previews of different file types using
Phoenix LiveView's uploads
feature.
In this example I use PDF and PDF.js to generate a preview of the uploaded PDF file.
Link to the writeup here
- Clone the repo
- Run
mix setup
to install dependencies - Start your Postgres database
- Run
mix phx.server
to start the server - Visit
http://localhost:4000
and upload a PDF file
- Official website: https://www.phoenixframework.org/
- Guides: https://hexdocs.pm/phoenix/overview.html
- Docs: https://hexdocs.pm/phoenix
- Forum: https://elixirforum.com/c/phoenix-forum
- Source: https://github.com/phoenixframework/phoenix