@sobagu/angular
v0.1.2
Published
Sobagu CSS for Angular: the standalone [sb] directive and the sb pipe
Maintainers
Readme
@sobagu/angular
Sobagu for Angular: the standalone [sb] directive styles any element with a style object, and the
sb pipe turns a style object into a class string for [class].
Install
npm i @sobagu/angularNeeds @angular/core 17 or newer. @sobagu/core is installed with it.
Usage
import { Component, signal } from '@angular/core'
import { SbDirective, SbPipe } from '@sobagu/angular'
@Component({
selector: 'app-card',
imports: [SbDirective, SbPipe],
template: `
<section [class]="{ card: true, md: { p: 'lg' } } | sb">
<button [sb]="{ p: 'md', _disabled: { opacity: 0.5 } }" [disabled]="saving()">Save</button>
</section>
`,
})
export class Card {
saving = signal(false)
}Docs
Sobagu is in 0.x: the API can still change between minor versions.
Licence
MIT © 2026 Sobagu contributors
