clsource
Liquor Tags - Fetch OpenGraph data and Render the output
Liquor Tags. Inspired by dev.to embed tags (liquid tags),
takes Open Graph data from URLs and generate output using pseudo EEx templates.
Useful when creating previews of websites using Open Graph data.
alias Liquor.Tags.Tag
content = """
{% github ElixirCL %}
{% embed https://ninjas.cl %}
"""
tags = [
Tag.new("github", "Github: <%= og.url %>", "https://github.com"),
Tag.new("embed", "Website: <%= og.title %>")
]
# Fetch only needs to return the HTML string
fetch = fn url -> Req.get!(url) |> then(& &1.body) end
Liquor.render(content, tags, fetch)
|> Kino.Text.new()
Popular in Announcing
In short
Plug n’ play OAuth 2.0 provider library. Just set up a resource owner schema with Ecto (your user schema), install the dependen...
New
I’ve published the first version of my Makeup library. It’s a syntax highlighter for Elixir in the spirit of Pygments, Currently it highl...
New
Hello :waving_hand:
Allow me to introduce you to Tz, an alternative time zone database support to Tzdata.
Why another library?
First a...
New
import Meeseeks.CSS
html = HTTPoison.get!("https://news.ycombinator.com/").body
for story <- Meeseeks.all(html, css("tr.athing")) do...
New
Presenting Aviacommerce, open source e-commerce platform in Elixir
Aviacommerce is an open source e-commerce platform in Elixir. We at...
New
You may know https://ui.shadcn.com/, a UI component library for React. I really love it’s design style and components. I’ve built some co...
New
ExApi is a library that I’m developing now and hope release soon
This library will allow to:
list all apis
list all api implementation...
New
After just over two years in development, this latest version of Pigeon is what I finally consider done in regards to my original vision ...
New
Lexical
Lexical is a next-generation language server for the Elixir programming language.
Features
Context aware code completion
As-you...
New
Grizzly is a library for working with Z-Wave devices. Z-Wave is a low-frequency radio protocol for controlling smart home devices on a me...
New
Other popular topics
lets say i have a sample like
a = 20; b = 10;
if (a > b) do
{:ok, "a"}
end
if (a < b) do
{:ok, b}
end
if (a == b) do
{:ok, "equa...
New
Posting this to see if we can make things easier for people to get into Neovim. If you use Neovim and have a favourite distro please let ...
New
Anybody knows a comprehensive comparison of Django and Phoenix, thanks for the help.
Where are they similar?
Where do they differ the m...
New
I believe there are people here who are dealing with CSV files import on the daily basis, and since Excel is a really popular tool there ...
New
I have seen a lot of code which picks the first element from a list using Enum.at(0) instead of List.first. Is there a reason why people ...
New
Surface is an experimental library built on top of Phoenix LiveView and its new LiveComponent API that aims to provide a more declarative...
New
Please see the new poll here: Which code editor or IDE do you use? (Poll) (2022 Edition)
It’s been a while since we first asked this, I...
New
I’ve read in another post that it may be possible with a router helper - but I couldn’t find an appropriate one, and tbh, I’m still just ...
New
In the code below, if the create action is not set to accept “extra_key” as an input, it errors out with a message shown above. Is there ...
New
Hi. I’ve noticed that Windows Powershell has it’s own IEX command and you cannot access Elixir’s IEX due to the conflict. This isn’t a cr...
New
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #deployment
- #library
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #channels
- #elixirconf
- #exunit
- #discussion
- #code-sync
- #javascript
- #podcasts
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #elixir-ls
- #phoenix_html
- #iex
- #blog-post
- #graphql
- #genstage
- #ai
- #websockets
- #supervisor
- #advent-of-code
- #elixirconf-us
- #distillery
- #processes
- #forms
- #api
- #metaprogramming
- #security
- #performance









