Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/bundler/deps.ts>postcss.Comment

A Bundler with the web in mind.
Go to Latest
class postcss.Comment
extends Node
Re-export
import { postcss } from "https://deno.land/x/bundler@0.6.5/deps.ts";
const { Comment } = postcss;

Represents a comment between declarations or statements (rule and at-rules).

Once (root, { Comment }) {
  let note = new Comment({ text: 'Note: …' })
  root.append(note)
}

Comments inside selectors, at-rule parameters, or declaration values will be stored in the raws properties explained above.

Constructors

new
Comment(defaults?: CommentProps)

Properties

raws: CommentRaws
text: string

The comment's text.

type: "comment"

Methods

clone(overrides?: Partial<CommentProps>): this
cloneAfter(overrides?: Partial<CommentProps>): this
cloneBefore(overrides?: Partial<CommentProps>): this