package ppx_css

  1. Overview
  2. Docs
Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source

Module Ppx_css_syntaxSource

Sourcemodule String_constant : sig ... end

This module parses a call to ppx_css into nicer parts to make the implementation of ppx_css cleaner.

Sourcetype t = {
  1. rewrite : Ppxlib.expression Core.String.Map.t;
    (*

    For a given (key, value) pair, value will "rewrite" itself wherever "key" is roughly: s/$key/$value/g

    Equivalent to the ~rewrite parameter in the call to stylesheet on ppx_css.

    *)
  2. css_string : String_constant.t;
    (*

    The contained CSS string. Equivalent to the string parameter given to ppx_css.

    *)
  3. dont_hash_prefixes : string list;
}
Sourceval parse_stylesheet : Ppxlib.expression -> t

Given the AST of an expression like stylesheet ~rewrite:[] "" will result in a "parsed" t.

stylesheet is the %css stylesheet {|stylesheet...|} syntax and expands to a module declaration.

Sourceval parse_inline_expression : Ppxlib.expression -> t

Given the AST of an expression like "" ~rewrite:[] will result in a "parsed" t

inline is the syntax %css {|declarations...|} and expands to an expression.

Sourceval empty_stylesheet : css_string:String_constant.t -> t
Sourcemodule Serializable_options : sig ... end
Sourcemodule Preprocess_arguments : sig ... end

This module contains the parameters sent in via the jbuild/dune file's preprocess field.

OCaml

Innovation. Community. Security.