
Security News
November CVEs Fell 25% YoY, Driven by Slowdowns at Major CNAs
November CVE publications fell 25% YoY even as 2025 totals rose, showing how a few major CNAs can swing βglobalβ counts and skew perceived risk.
@charmland/lipgloss
Advanced tools
The lipgloss that you know and love, now in JavaScript.
[!WARNING] LipGloss.js is stll experimental.
npm i @charmland/lipgloss
const { Table, TableData, Style, Color, List, Tree, Leaf, Bullet, RoundedEnumerator } = require("@charmland/lipgloss");
var s = new Style().foreground(Color("240")).render;
console.log(
new Table()
.wrap(false)
.headers("Drink", "Description")
.row("Bubble Tea", s("Milky"))
.row("Milk Tea", s("Also milky"))
.row("Actual milk", s("Milky as well"))
.render(),
);
// TableData example - for more complex data management
const employeeData = new TableData(
["Employee ID", "Name", "Department"],
["001", "John Doe", "Engineering"],
["002", "Jane Smith", "Marketing"],
["003", "Mike Johnson", "Sales"]
);
console.log(
new Table()
.data(employeeData)
.styleFunc((row, col) => {
if (row === -1) {
return new Style().foreground(Color("99")).bold(true);
}
return new Style().padding(0, 1);
})
.render()
);
// List example
const groceries = new List("Bananas", "Barley", "Cashews", "Milk")
.enumerator(Bullet)
.itemStyle(new Style().foreground(Color("255")));
console.log(groceries.render());
// Tree example with Leaf nodes
const makeupTree = new Tree()
.root("β Makeup")
.child(
"Glossier",
"Fenty Beauty",
new Tree().child(
new Leaf("Gloss Bomb Universal Lip Luminizer"),
new Leaf("Hot Cheeks Velour Blushlighter")
),
new Leaf("Nyx"),
new Leaf("Mac"),
"Milk"
)
.enumerator(RoundedEnumerator)
.enumeratorStyle(new Style().foreground(Color("63")).marginRight(1))
.rootStyle(new Style().foreground(Color("35")))
.itemStyle(new Style().foreground(Color("212")));
console.log(makeupTree.render());
The TableData class provides a more structured way to manage table data compared to using individual rows. It's particularly useful when you need to:
const { Table, TableData, Style, Color } = require("@charmland/lipgloss");
// Create TableData with initial rows
const data = new TableData(
["Name", "Age", "City"],
["Alice", "25", "New York"],
["Bob", "30", "San Francisco"]
);
// Or build it incrementally
const data2 = new TableData()
.append(["Product", "Price"])
.append(["Laptop", "$999"])
.append(["Mouse", "$25"]);
// Use with Table
const table = new Table()
.data(data)
.styleFunc((row, col) => {
if (row === -1) return new Style().bold(true); // Header
return new Style().padding(0, 1);
})
.render();
new TableData(...rows) - Create with optional initial rows.append(row) - Add a single row (array of strings).rows(...rows) - Add multiple rows at once.at(row, col) - Get value at specific position.rowCount() - Get number of rows.columnCount() - Get number of columnsSee examples/table-data.js for more comprehensive examples.
You can control debug output using environment variables:
LIPGLOSS_DEBUG=true - Enable all lipgloss debug outputDEBUG=lipgloss - Enable lipgloss debug output (standard debug pattern)DEBUG=* - Enable all debug outputExample:
node your-script.js
Lipgloss in JavaScript it's experimental and a lot of existing functionalities are not still ported to JavaScript.
| Function | Status |
|---|---|
Width | β |
Height | β |
Size | β |
| Function | Status |
|---|---|
Color | β |
NoColor | β |
Complete | β |
LightDark | β |
RGBA | β |
| Function | Status |
|---|---|
NormalBorder | β |
RoundedBorder | β |
BlockBorder | β |
OuterHalfBlockBorder | β |
InnerHalfBlockBorder | β |
ThickBorder | β |
DoubleBorder | β |
HiddenBorder | β |
MarkdownBorder | β |
ASCIIBorder | β |
| Function | Status |
|---|---|
Foreground | β |
Background | β |
Width | β |
Height | β |
Align | β |
AlignHorizontal | β |
AlignVertical | β |
Padding | β |
PaddingLeft | β |
PaddingRight | β |
PaddingTop | β |
PaddingBottom | β |
ColorWhitespace | β |
Margin | β |
MarginLeft | β |
MarginRight | β |
MarginTop | β |
MarginBottom | β |
MarginBackground | β |
Border | β |
BorderStyle | β |
SetBorderRight | β |
SetBorderLeft | β |
SetBorderTop | β |
SetBorderBottom | β |
BorderForeground | β |
BorderTopForeground | β |
BorderRightForeground | β |
BorderBottomForeground | β |
BorderLeftForeground | β |
BorderBackground | β |
BorderTopBackground | β |
BorderRightBackground | β |
BorderBottomBackground | β |
BorderLeftBackground | β |
Inline | β |
MaxWidth | β |
MaxHeight | β |
TabWidth | β |
UnderlineSpaces | β |
Underline | β |
Reverse | β |
SetString | β |
Inherit | β |
Faint | β |
Italic | β |
Strikethrough | β |
StrikethroughSpaces | β |
Transform | β³ |
| Function | Status |
|---|---|
table.New | β |
table.Rows | β |
table.Headers | β |
table.Render | β |
table.ClearRows | β |
table.BorderTop | β |
table.BorderBottom | β |
table.BorderLeft | β |
table.BorderRight | β |
table.BorderHeader | β |
table.BorderColumn | β |
table.BorderRow | β |
table.Width | β |
table.Height | β |
table.Offset | β |
table.String | β |
table.StyleFunc | β |
table.Data | β |
table.Border | β |
table.BorderStyle | β |
| Function | Status |
|---|---|
Hidden | β |
Hide | β |
Offset | β |
Value | β |
String | β |
Indenter | β |
ItemStyle | β |
ItemStyleFunc | β |
EnumeratorStyle | β |
EnumeratorStyleFunc | β |
Item | β |
Items | β |
Enumerator | β |
| Function | Status |
|---|---|
tree.New | β |
tree.Root | β |
tree.Child | β |
tree.Hidden | β |
tree.Hide | β |
tree.SetHidden | β |
tree.Offset | β |
tree.Value | β |
tree.SetValue | β |
tree.String | β |
tree.Render | β |
tree.EnumeratorStyle | β |
tree.EnumeratorStyleFunc | β |
tree.ItemStyle | β |
tree.ItemStyleFunc | β |
tree.RootStyle | β |
tree.Enumerator | β |
tree.Indenter | β |
tree.DefaultEnumerator | β |
tree.RoundedEnumerator | β |
tree.DefaultIndenter | β |
NewLeaf | β |
Leaf.Value | β |
Leaf.SetValue | β |
Leaf.Hidden | β |
Leaf.SetHidden | β |
Leaf.String | β |
| Custom Enumerators | β³ |
| Custom Indenters | β³ |
| Function | Status |
|---|---|
JoinHorizontal | β |
JoinVertical | β |
| Function | Status |
|---|---|
Center | β |
Right | β |
Bottom | β |
Top | β |
Left | β |
Place | β |
| Function | Status |
|---|---|
BackgroundColor | β³ |
HasDarkBackground | β |
| Function | Status |
|---|---|
EnableLegacyWindowsANSI | β³ |
We'd love to have you contribute! Please see the contributing guidelines for more information.
The JavaScript bindings include a comprehensive test suite:
# From bindings directory
npm test # Run all tests
npm run test:simple # Basic table functionality
npm run test:comprehensive # Complete TableData tests
npm run examples # Showcase functionality
# Or from examples directory
cd examples && npm test
Tests are located in examples/tests/ and cover:
See contributing.
Weβd love to hear your thoughts on this project. Feel free to drop us a note!
Part of Charm.
Charmηη±εΌζΊ β’ Charm loves open source
FAQs
Style definitions for nice terminal layouts π
The npm package @charmland/lipgloss receives a total of 1 weekly downloads. As such, @charmland/lipgloss popularity was classified as not popular.
We found that @charmland/lipgloss demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago.Β It has 7 open source maintainers collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
November CVE publications fell 25% YoY even as 2025 totals rose, showing how a few major CNAs can swing βglobalβ counts and skew perceived risk.

Security News
React disclosed a CVSS 10.0 RCE in React Server Components and is advising users to upgrade affected packages and frameworks to patched versions now.

Research
/Security News
We spotted a wave of auto-generated βelf-*β npm packages published every two minutes from new accounts, with simple malware variants and early takedowns underway.