Skip to content

Latest commit

 

History

History
30 lines (21 loc) · 333 Bytes

Readme.md

File metadata and controls

30 lines (21 loc) · 333 Bytes

style-canvas

Use CSS to style canvas paths

Installation

$ component install Swatinem/style-canvas

Example

.stroke {
  stroke: #ccc;
  stroke-width: 5;
  stroke-linejoin: round;
  stroke-linecap: round;
}
ctx.beginPath();
[]
styleCanvas(ctx, '.stroke');
ctx.stroke();

License

GPLv3