microformats
    TypeScript icon, indicating that this package has built-in type declarations

    0.0.1 • Public • Published

    Microformats

    Helper objects to more easily add microformats2 markup to your applications.

    Installation

    npm install microformats

    Usage

    microformats works best in an IDE like Visual Studio Code or with Typescript so you can benefit from autocompletion and inline documentation.

    import { CARD, ENTRY } from 'microformats';
    
    console.log(CARD.root);
    // 'h-card'
    
    console.log(ENTRY.name);
    // 'p-name'

    Example

    Adding microformats2 properties to your markup in a more legible way:

    <article className={`article pink-background ${ENTRY.root}`}>
      <h1 className={ENTRY.name}>Some title</h1>
      <div className={ENTRY.content}>Lorem ipsum...</div>
    </article>

    Contributing

    This project currently contains a small subset of the properties available in microformats2. If you want to request or add any more properties please create an issue.

    Install

    npm i microformats

    DownloadsWeekly Downloads

    5

    Version

    0.0.1

    License

    MIT

    Unpacked Size

    5.81 kB

    Total Files

    4

    Last publish

    Collaborators

    • lukehansford