Laravel EnsoLaravel Enso
Guide
Back End
Front End
GitHub
Guide
Back End
Front End
GitHub
  • Front End

    • Accessories
    • Addresses
    • Algolia
    • Audits
    • Auth
    • Bookmarks
    • Calendar
    • Card
    • Cargo Partner
    • Categories
    • Charts
    • Checkbox
    • Clipboard
    • Comments
    • Commercial
    • Companies
    • Confirmation
    • Currencies
    • Data Import
    • Date
    • Datepicker
    • Directives
    • Discounts
    • Divider
    • Documents
    • Dropdown
    • Dropdown Indicator
    • Eav
    • Emag
    • Emails
    • Enums
    • ERD
    • Facebook
    • Files
    • Filters
    • Financials
    • Forms
    • Frisbo
    • Google
    • Holidays
    • How to
    • Interactions
    • Inventory
    • IO
    • Laravel Validation
    • Loader
    • Localisation
    • Logs
    • Measurement Units
    • Meili Search
    • Menus
    • Mixins
    • Modal
    • Money
    • Monitored Emails
    • Notifications
    • Orderable Trees
    • Packaging Units
    • Pagination
    • People
    • Permissions
    • Product Lots
    • Products
    • Progress Bar
    • Progress Circle
    • Progress Indicator
    • Questionnaires
    • Quick View
    • Range Slider
    • Rating
    • Roles
    • Route Mapper
    • Sale Channels
    • Scroll to Top
    • Search Mode
    • Select
    • Sentry
    • Services
    • Smart Bill
    • SMS Advert
    • Strings
    • Switch
    • Tables
    • Tabs
    • Tasks
    • Teams
    • Textarea
    • Themes
    • Ticketing
    • Toastr
    • Transitions
    • Tree View
    • Tutorials
    • Typeahead
    • Typesense
    • UI
    • Uploader
    • UPS
    • User Groups
    • Users
    • Virtual Call Center
    • Vouchers
    • Webshop
    • WYSIWYG

ERD

LicenseStableDownloadsVueJavaScriptSCSSnpmIssuesMerge Requests

Description

ERD is a renderless ResizeObserver wrapper that exposes the current element width and height to slot content.

Installation

Install the package:

yarn add @enso-ui/erd

The component can be used inside or outside the Enso ecosystem.

Features

  • exports a single renderless Erd component through the package root
  • observes the rendered element with ResizeObserver and debounces updates
  • passes reactive width and height values to the default slot
  • works well for responsive charts, virtualized layouts, and adaptive cards

Usage

<script setup>
import Erd from '@enso-ui/erd';
</script>

<Erd :debounce="50" v-slot="{ width, height }">
    <div>{{ width }} × {{ height }}</div>
</Erd>

API

Erd

Renderless component that observes its own element box and forwards the current size through the default slot.

Import: @enso-ui/erd

Props:

  • debounce: number = 1 debounce window, in milliseconds, used before width and height updates are applied.

Events:

  • none.

Slots:

  • default receives { width, height } with the latest observed content-box dimensions.

Depends On

  • lodash for the internal debounce helper.
  • vue as the component runtime.

Contributions

are welcome. Pull requests are great, but issues are good too.

Thank you to all the people who already contributed to Enso!

License

MIT

Edit this page on GitHub
Last Updated: 4/21/2026, 12:25:53 PM
Prev
Enums
Next
Facebook