Have ideas to improve npm?Join in the discussion! »

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

    8.1.0 • Public • Published

    Creepyface Tilt · GitHub license npm version

    A point provider for Creepyface to make your face follow the tilt of your device.

    Example animated gif of a face looking at the tilt

    Usage

    <script src="https://creepyface.io/creepyface.js"></script>
    <script src="https://unpkg.com/creepyface-tilt"></script>
    
    <img
      data-creepyface
      data-points="tilt"
      src="https://creepyface.io/img/0/serious"
      data-src-look-0="https://creepyface.io/img/0/0"
      data-src-look-45="https://creepyface.io/img/0/45"
      data-src-look-90="https://creepyface.io/img/0/90"
      data-src-look-135="https://creepyface.io/img/0/135"
      data-src-look-180="https://creepyface.io/img/0/180"
      data-src-look-225="https://creepyface.io/img/0/225"
      data-src-look-270="https://creepyface.io/img/0/270"
      data-src-look-315="https://creepyface.io/img/0/315"
    />

    Run this example on codepen.

    Developing

    • yarn dev will spin up a test page.
    • yarn build will generate the production scripts under the dist folder.

    Install

    npm i creepyface-tilt

    DownloadsWeekly Downloads

    23

    Version

    8.1.0

    License

    MIT

    Unpacked Size

    5.79 kB

    Total Files

    5

    Last publish

    Collaborators

    • avatar