Skip to content

Latest commit

 

History

History
59 lines (40 loc) · 1.36 KB

README.md

File metadata and controls

59 lines (40 loc) · 1.36 KB

Sanity QR Code Generator Plugin (for Sanity Studio v3)

Instalation

To install this plugin, use the following command:

npm install sanity-qr-code-generator

Usage

To use this plugin, add it as a plugin in your sanity.config.ts (or .js) file, as shown in the example below:

import {defineConfig} from 'sanity'
import {QrCodeGenerator} from 'sanity-qr-code-generator'

export default defineConfig({
  //..
  plugins: [.., .., QrCodeGenerator()],

})

Then you can use 'qrCode' as custom type in your schemas.

    defineField({
      title: 'Generate your QR code',
      name: 'qrCode',
      type: 'qrCode',
    })

Example

QR generator plugin in use

Develop & test

This plugin uses @sanity/plugin-kit with default configuration for build & watch scripts.

See Testing a plugin in Sanity Studio on how to run this plugin with hotreload in the studio.

Word from author

Have fun ✌️

Supported by Halo lab