Theme
Tutorial

Building Your First Construct Plugin

Flakerim Ismani · · 1 min read

Plugins extend Construct spaces with new capabilities.

Plugin Structure

my-plugin/
  plugin.yaml
  src/index.ts
  package.json

Plugin Code

import { definePlugin } from 'construct-sdk'

export default definePlugin({
  name: 'analytics-widget',
  setup(ctx) {
    ctx.ui.registerWidget({
      id: 'analytics',
      title: 'Analytics',
      component: () => import('./AnalyticsPanel.vue')
    })
  }
})

Plugins are sandboxed — they can only access what their permissions allow.