IgniterCss.ParseOpts (igniter_css v1.0.0)

Copy Markdown View Source

Parser options handed to the native layer.

  • :allow_wrong_line_comments — treat // as a comment. On by default: the habit leaks in from css-in-js tooling often enough to be worth tolerating, and it cannot lose data either way (with the flag off those bytes become error-tolerant nodes that still carry their text).
  • :css_modules — enable CSS Modules syntax (:global, composes).

Summary

Functions

Build options from a keyword list, falling back to the defaults.

Types

t()

@type t() :: %IgniterCss.ParseOpts{
  allow_wrong_line_comments: boolean(),
  css_modules: boolean()
}

Functions

new(opts)

@spec new(keyword() | t()) :: t()

Build options from a keyword list, falling back to the defaults.

iex> IgniterCss.ParseOpts.new(css_modules: true).css_modules
true