Lion Logo Lion Fundamentals Guides Components Blog Toggle darkmode

Button: Extensions

Bootstrap button

const capitalize = s => s[0].toUpperCase() + s.slice(1);

export const bootstrapButton = () => {
  const variants = [
    'primary',
    'secondary',
    'success',
    'danger',
    'warning',
    'info',
    'light',
    'dark',
    'link',
  ];

  return html`<div>
    ${variants.map(v => html`<bootstrap-button variant="${v}">${capitalize(v)}</bootstrap-button>`)}
  </div>`;
};