Skip to content

badgeteam/mch2022-webusb-site

Repository files navigation

MCH2022 badge WebUSB companion

Look at the Nuxt 3 documentation to learn more.

Setup

Make sure to install the dependencies:

# yarn
yarn install

Development

Start the development server on http://localhost:3000

yarn dev

Access BadgeUSB API

The BadgeAPI is available through the plugin set up in plugins/badgeUSB.client.ts. You can use it in a page or component like this:

<template>
  ...
</template>

<script lang="ts" setup>
const { $BadgeAPI } = useNuxtApp();

/* do stuff */
</script>

Production

Build the application for production:

yarn build

Locally preview production build:

yarn preview

Check out the deployment documentation for more information.