Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Laravel Options Creator Laravel Package

michalkortas/laravel-options-creator

View on GitHub
Deep Wiki
Context7

laravel-options-creator

Wrapper that helps create options at select element dynamically

Installation

Warning! This component use Bootstrap Modal!

composer require michalkortas/laravel-options-creator
php artisan vendor:publish --tag=optionscreator --force

Usage

Add new stacks before end of tag.

<body>
  ...
  @stack('scripts')
  @stack('optionscreator')
</body>

Wrap your select with new tag. You can use some parameters to configure modal.

  <x-optionscreator-select
      url="{{route('store.api.route')}}"
      component="components.subEditForm"
      successValueKey="id"
      successTextKey="name"
      title="New option"
      saveButtonTitle="Create new option"
      loadingText="Please wait..."
      successText="<strong>New option has beed added</strong> to your select tag."
      errorText="<strong>Error occurred</strong>. Check console log."
      setNewValue="1">

      <select name="mySelect">
        <option>Select value</option>
      </select>
  </x-optionscreator-select>

This component will do the rest.

Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
codifyo/ts-generator-bundle
andydefer/laravel-cluster
testo/fiber
mintobit/jobqueue
a4sex/maintenance-bundle
a4sex/entity-date-update
a4sex/client-identifier
a4sex/base-utilites
a4sex/key-value-storage
a4sex/micro-status
chilldev/dependency-injection-extra
datinglibre/datinglibre-app-api
biberltd/corebundle
bricre/symfony-bundle-test
biberltd/logbundle
dominium/http-adapter-bundle
dominium/google-analytics
a4sex/auto-clean-entity
christhompsontldr/laravel-inky
spatie/mailcoach-vapor