npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@dcodegroup-au/laravel-attachments-vue

v1.0.0

Published

Vue frontend components for Laravel Attachments.

Downloads

210

Readme

Laravel Attachments Vue Frontend

Vue frontend components for the Laravel Attachments media UI, packaged for npm.

  • Vue components in src/components
  • Shared mixins in src/mixins
  • SCSS styles in src/styles
  • A Vue plugin entrypoint in src/plugin.js
  • A library build entrypoint in src/index.js

Install

npm install @dcodegroup/laravel-attachments-vue

The package expects Vue 3 to be installed by the consuming application.

Usage

Register the plugin and import the bundled styles in your application entry file:

import { createApp } from "vue";
import attachmentPlugin from "@dcodegroup/laravel-attachments-vue";
import "@dcodegroup/laravel-attachments-vue/style.css";

const app = createApp({});

app.use(attachmentPlugin, {
  media: {
    words: {
      home: "Home",
      title: "Attachments",
      select_existing: "Select existing",
    },
    headings: {
      model: "Model",
      parent: "Parent",
    },
    table: {
      headings: {
        details: "Details",
        category: "Category",
        title: "Title",
        alt_text: "Alt text",
        size: "Size",
        uploaded_by: "Uploaded by",
        created_at: "Created at",
        select_existing: "Select existing",
      },
    },
  },
});

app.mount("#app");

The plugin globally registers the Attachments component.

<template>
  <Attachments
    :model="model"
    model-class="App\\Models\\Post"
    upload-endpoint="/frontend/admin/media/upload"
    model-existing-endpoint="/frontend/admin/media/existing"
    category-options-endpoint="/frontend/admin/category/options"
    categories-endpoint="/frontend/admin/category/options"
  />
</template>

You can also import individual components:

import { Attachments, MediaList, Upload } from "@dcodegroup/laravel-attachments-vue";

Runtime expectations

These components are frontend-only and do not include the Laravel routes, controllers, models, migrations, config, views, or translations from the original Composer package.

The consuming application must provide:

  • Backend API endpoints that match the component props you configure.
  • A global axios instance for API requests.
  • A global lodash-compatible _ instance for the existing helper calls in the components.
  • Translation options passed to app.use(attachmentPlugin, translations) for strings accessed through $t().

Styles

Import the built CSS:

import "@dcodegroup/laravel-attachments-vue/style.css";

Or import the SCSS source if your build pipeline compiles Sass:

@import "@dcodegroup/laravel-attachments-vue/scss";

Development

Install dependencies:

npm install

Run linting:

npm run lint

Build the npm package artifacts:

npm run build

The Vite library build emits ESM, UMD, and CSS artifacts to dist/.