LiveViewNative.Stylesheets (live_view_native v0.2.0)

Provides runtime support for LiveView Native's stylesheet system.

Summary

Functions

Returns a map containing all class names for templates within the given LiveView, LiveComponent or Phoenix Components module. tree_key can be passed for retrieving a specific class tree; this should only used for modules which have multiple tree shaking passes applied at compile-time (for example, layout modules), otherwise :default should be passed.

Returns the internal class tree module for the given LiveView, LiveComponent or Phoenix Components module.

Compiles all stylesheets for the given class tree and returns them as a single map.

Functions

Link to this function

get_class_tree(class_tree_module, tree_key \\ :default, opts \\ [])

Returns a map containing all class names for templates within the given LiveView, LiveComponent or Phoenix Components module. tree_key can be passed for retrieving a specific class tree; this should only used for modules which have multiple tree shaking passes applied at compile-time (for example, layout modules), otherwise :default should be passed.

Link to this function

get_class_tree_module(module)

Returns the internal class tree module for the given LiveView, LiveComponent or Phoenix Components module.

Link to this function

reduce_stylesheets(map, stylesheet_modules)

Compiles all stylesheets for the given class tree and returns them as a single map.