package cascade

  1. Overview
  2. Docs
CSS generation and manipulation library for OCaml

Install

dune-project
 Dependency

Authors

Maintainers

Sources

cascade-1.1.0.tbz
sha256=c303651e043ed8d807d3d6f2c3745233e792ce7c30d562c9717d284e1bf5ac6a
sha512=681847993deabdc3899f62268b3cbc931623abca0413b0e8873e8568ec25a86c4d3db7f7f0e6a6a6bf24dbfdc7df314dae07ae66d49f76f3dd6953a4381bbf54

doc/cascade/Cascade/Rule/index.html

Module Cascade.RuleSource

Rule-local optimization passes.

Optimize one rule without descending into nested statements.

Sourceval finalize : ?canonicalize_selector:bool -> ctx:Ctx.t -> Stylesheet.rule -> Stylesheet.rule

Final declaration cleanup before a rule leaves the fixpoint.

Sourceval drop_shadowed : Stylesheet.rule list -> Stylesheet.rule list

Drop same-selector shadowed rules and declarations.

Sourceval merge_adjacent_identical : ctx:Ctx.t -> Stylesheet.rule list -> Stylesheet.rule list

Merge each maximal run of adjacent rules whose declaration bodies are identical into one selector-list rule. Cascade-safe for any DOM: the same declarations apply either way. Runs with the always-on local rewrites, independent of the gated global factoring.