netoum

netoum

Designex - Mix tasks for installing and invoking designex via the stand-alone designex cli

Designex is a cli tool that helps you get started with Design tokens.

Get easily started with design tokens using Designex CLI. Features a wide range of templates, pre-built configurations, and live reloading for seamless design system integration.

The Elixir library allows you to run Design CLI without the need for Nodejs similar to Tailwind Elixir

  • :rocket: Quick Start - Run Designex Setup to setup ready-to-use token templates and get your project running in seconds.
  • :hammer: Easy Build - Use Designex Build to convert your tokens into platform-ready formats.
  • :eyes: Live Updates - Use Designex Build Watch to see changes instantly while you work.

The elixir librairy is available on:

https://github.com/netoum/designex


Examples with Phoenix, Tailwind v3 and v4.

Design CLI documention:

The Cli is build with Oclif. A great and efficient Cli framework, check it out.

Templates:

Depending on the template selected it will use the following dependencies:

Tailwind v4

This templates follows the latest setup of [Tailwind v4] (https://tailwindcss.com).
It will generate Tailwind v4 CSS files to import into your main css assets.

You can choose from style dictionary or tokens studio format.
If you are using the free version of Tokens Studio you must select single file.

  • tailwind/v4/tokens-studio/single
  • tailwind/v4/tokens-studio/multi
  • tailwind/v4/style-dictionary

Tailwind v3

This templates follows the legacy setup of [Tailwind v3] (https://tailwindcss.com).
It will generate Tailwind v3 JS files to import into your Tailwind Config file.
You can choose from tokens studio single and multi format.
If you are using the free version of Tokens Studio you must select single file.

  • tailwind/v3/tokens-studio/single
  • tailwind/v3/tokens-studio/multi

Shadcn

This templates follows the latest setup of [Shadcn] (Introduction - shadcn/ui).
It will generate Tailwind v3 JS files to import into your Tailwind Config file.
You must also add the generate CSS files for the default and dark mode.
The colors are converted to hsl as advised by Shadcn
You can choose from style dictionary or tokens studio format.
If you are using the free version of Tokens Studio you must select single file.

  • shadcn/tokens-studio/single
  • shadcn/tokens-studio/multi
  • shadcn/style-dictionary
// Tailwind Config
  theme: {
    extend: {
      textColor: require("./build/shadcn/textColor.js"),
      colors: require("./build/shadcn/colors.js"),
      backgroundColor: require("./build/shadcn/backgroundColor.js")
    }

Shadcn Css

// CSS Import


@import "../build/css/shadcn.css";
@import "../build/css/shadcn/modes/light.css";

Material

This templates is an export of the Material 3 Design Kit Figma file and the Material Theme Builder Figma Plugin
You can choose from style dictionary or tokens studio format.
If you are using the free version of Tokens Studio you must select single file.

  • material/tokens-studio/single
  • material/tokens-studio/multi
  • material/style-dictionary

Mozilla

This templates is an export of the legacy Mozilla Design Tokens
You can choose from tokens studio single and multi format.
If you are using the free version of Tokens Studio you must select single file.

  • mozilla/tokens-studio/single
  • mozilla/tokens-studio/multi

Most Liked

mindok

mindok

Thanks! I had the same question.

I think there are quite a few grey-hairs in the Elixir community (myself included) who prefer doing almost anything else over tinkering with CSS, so it’s worth taking the time to explain the problem context and the problem your library solves.

Welcome to the community BTW, and thanks for your work on this library.

Exadra37

Exadra37

I should have made my question a little more specific and clear.

To be clear my question was made to make you realise that your topic doesn’t address users that have no clue what are design tokens, thus no idea what this is useful for. I know we can google it, but as someone that worked before as a Developer Advocate I would recommend you to be more specific in your promotion of your package to help increase it’s adoption among people unaware of what are design tokens.

dimitarvp

dimitarvp

…what even are “design tokens”?

Where Next?

Popular in Announcing Top

mischov
import Meeseeks.CSS html = HTTPoison.get!("https://news.ycombinator.com/").body for story <- Meeseeks.all(html, css("tr.athing")) do...
New
jakub-zawislak
Hi everyone, I’m coming from the Symfony (PHP) framework. I like Phoenix, but it has a one thing that was build much better in the Symfo...
New
tmbb
I’ve been working on two packages (not on hex.pm yet) to build admin interfaces for phoenix apps: bureaucrat - which contains a bunch ...
New
oltarasenko
Dear Elixir community, After a year of development, bug fixes, and improvements, we are proudly ready to share the release of Crawly 0.1...
New
nikokozak
Hello all, I’ve been working on Svonix - a library for quickly integrating Svelte components into Phoenix views. It’s a much-needed succ...
New
kip
Image is an image processing library for Elixir. It is based upon the fabulous vix library that provides a libvips wrapper for Elixir. I...
622 18934 194
New
RobertDober
Earmark is a pure-Elixir Markdown converter. It is intended to be used as a library (just call Earmark.as_html), but can also be used as...
239 12645 134
New
Flo0807
Hello everyone! I am excited to share our heart project Backpex with you. After building several Phoenix applications, we realized that...
New
markmark206
simple_feature_flags is a tiny package that lets you turn features on or off based on which environment (e.g. localhost, staging, product...
New
marcuslankenau
I feel kind of stuck with the absence of a proper xml library for Elixir. Currently I use SweetXML which was ok for me more or less to pa...
New

Other popular topics Top

hariharasudhan94
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
chrismccord
As promised, the first release candidate of Phoenix 1.3.0 is out! This release focuses on code generators with improved project structure...
New
lessless
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
greenz1
I have a phoenix application from which a user can download multiple(5-6) files of size 1MB. I couldn’t find anything related to sending ...
New
belgoros
I’m not a pro in using Regex and can’t figure out why the following behaviour happens, especially if we take into account the difference ...
New
stefanchrobot
What’s the safe way to decode a JSON string into a struct? I want to avoid calling String.to_atom. Jason.decode can give me a map with st...
New
jay1
Why is it that the mnesia database isn’t the most preferred database for use in Elixir/Phoenix?
New
jason.o
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
shijith.k
I am trying to start a new phoenix project with elixir 1.9, but mix phx.new does not work. It says that ** (Mix) The task "phx.new" could...
New
jononomo
For some reason my phoenix channels are working for me in my local dev environment, but as soon as I deploy via Docker, I get a 403 error...
New

Latest on Elixir Forum

Elixir Forum

We're in Beta

About us Mission Statement