LineaUI.Installer.Assets (linea_ui v0.3.0)

Copy Markdown View Source

The steps of mix linea_ui.install that edit the app's own assets: assets/css/app.css and assets/js/app.js.

Each step is idempotent and, when it cannot find the place to edit, adds a warning to the Igniter and leaves the file alone.

Summary

Functions

Imports LineaUI's fonts and styles in assets/css/app.css.

Imports LineaHooks in assets/js/app.js and spreads them into the LiveSocket hooks.

Functions

css(igniter, opts)

@spec css(Igniter.t(), keyword()) :: Igniter.t()

Imports LineaUI's fonts and styles in assets/css/app.css.

Options: :replace_daisyui removes the daisyUI and heroicons plugins, :hugeicons adds the Hugeicons plugin. daisyUI left in place gets a warning, as the two stylesheets can conflict.

js(igniter)

@spec js(Igniter.t()) :: Igniter.t()

Imports LineaHooks in assets/js/app.js and spreads them into the LiveSocket hooks.