ml_switcheroo.compiler.backends.sass.emitter ============================================ .. py:module:: ml_switcheroo.compiler.backends.sass.emitter .. autoapi-nested-parse:: SASS Emitter (Backend). Converts SASS AST nodes into formatted assembly text. Classes ------- .. autoapisummary:: ml_switcheroo.compiler.backends.sass.emitter.SassEmitter Module Contents --------------- .. py:class:: SassEmitter Converts SASS AST nodes into textual assembly code. .. py:method:: emit(nodes: List[ml_switcheroo.compiler.frontends.sass.nodes.SassNode]) -> str Generates the SASS source string from a list of nodes. Formatting Rules: - Labels (e.g. `L_1:`) are rendered flush-left. - All other nodes are indented by 4 spaces. :param nodes: AST nodes. :type nodes: List[SassNode] :returns: The formatted SASS source code string. :rtype: str