Skip to content

pantoken / renderers/bootstrap/src / toBootstrapCss

Fungsi: toBootstrapCss()

toBootstrapCss(options?): string

Eksperimental

Terbitkan jambatan pembolehubah CSS Bootstrap → Instructure.

Parameter

options?

ToBootstrapCssOptions = {}

ToBootstrapCssOptions.

Mengembalikan

string

Rentetan CSS jambatan.

Contoh

Jambatan :root lalai

ts
import { toBootstrapCss } from "@pantoken/bootstrap";

const css = toBootstrapCss();
// ":root { --bs-primary: var(--instui-color-background-brand); … }"

Hadkan kepada atribut tema Bootstrap

ts
import { toBootstrapCss } from "@pantoken/bootstrap";

const css = toBootstrapCss({ selector: "[data-bs-theme]" });