Naming Prosecution Mitigator

    @adamlacombe/fa-icon
    TypeScript icon, indicating that this package has built-in type declarations

    1.0.0 • Public • Published

    Built With Stencil

    @adamlacombe/fa-icon

    A web component for Font Awesome 5

    See it in action on codepen.io

    Examples

    TSX

    import { Component, h, Host } from '@stencil/core';
    import '@adamlacombe/fa-icon';
    
    @Component({
      tag: 'my-component'
    })
    export class MyComponent {
    
      render() {
        return <Host>
          <fa-icon type={'far'} name={'surprise'} size={'medium'} />
        </Host>;
      }
    }

    HTML

    <script src='https://unpkg.com/@adamlacombe/fa-icon@latest/dist/fa-icon.js'></script>
    
    <fa-icon type="far" name="surprise" size="medium"></fa-icon>

    Using this component

    Script tag

    • Put a script tag similar to this <script src="https://unpkg.com/@adamlacombe/fa-icon@latest/dist/fa-icon.js"></script> in the head of your index.html
    • Then you can use the element anywhere in your template, JSX, html etc

    In a stencil project

    • Run npm install @adamlacombe/fa-icon --save
    • Add an import to the npm package import '@adamlacombe/fa-icon';
    • Then you can use the element anywhere in your stencil project.

    Install

    npm i @adamlacombe/fa-icon

    DownloadsWeekly Downloads

    96

    Version

    1.0.0

    License

    MIT

    Unpacked Size

    7.16 MB

    Total Files

    62

    Last publish

    Collaborators

    • adamlacombe