0.0.6 • Published 4 years ago

nuxt-blurhash v0.0.6

Weekly downloads
23
License
ISC
Repository
github
Last release
4 years ago

Nuxt Blurhash

Demo

📖 Release Notes

this project based on https://github.com/damienroche/vue-blurhash

Setup

  1. Add nuxt-blurhash dependency to your project
yarn add nuxt-blurhash # or npm install nuxt-blurhash
  1. Add nuxt-blurhash to the modules section of nuxt.config.js
{
  modules: [
    // Simple usage
    'nuxt-blurhash'
  ]
}

Props

NameTypeDefaultDescription
heightNumber, String128Height of image
widthNumber, String128Width of image
punchNumber, String1This value adjusts the contrast on the decoded image
srcStringnullImage source url
transitionDurationNumber500Fade animation - Transition time (in ms)

Simple usage

<template>
  <nuxt-blur-image
    width="400"
    height="300"
    src="https://images.unsplash.com/photo-1417325384643-aac51acc9e5d?q=75&fm=jpg&w=1080&fit=max"
    hash="LFC$yHwc8^$yIAS$%M%00KxukYIp"
    alt="A man drinking a coffee."
  />
</template>

Use Canvas only

<template>
  <nuxt-blurhash
    :hash="'LdHfL}oJR$WBKnfi%3ofT0kCM{ay'"
    :width="'340'"
    :height="'320'"
    :punch="punch"
  />
</template>
0.0.6

4 years ago

0.0.5

4 years ago

0.0.4

4 years ago

0.0.3

4 years ago

0.0.2

4 years ago