@khodakhah/inertia-form
TypeScript icon, indicating that this package has built-in type declarations

0.1.4 • Public • Published

inertia-form

This is a vue component to create InertiaJs forms from an object.

Installation

npm install @khodakhah/inertia-form

Usage

In YourComponent.vue file:

<template>
  <div>
    <InertiaForm :inputs="inputs"/>
  </div>
</template>

<script setup>
import { InertiaForm } from '@khodakhah/inertia-form.vue'
const inputs = [
  {
    key: 'first_name'
    type: 'text',
    label: 'First Name',
  },
  { 
    key: 'last_name'
    type: 'text',
    label: 'Last Name',
  },
  {
    key: 'email'
    type: 'email',
    label: 'Email',
  },
]
</script>

Development

# Clone the repository
git clone https://github.com/khodakhah/form-vue.git

# Go to the project directory
cd form-vue

# Set npm version
nvm use

# Install dependencies
npm install

# Run the development server
npm run serve

Readme

Keywords

Package Sidebar

Install

npm i @khodakhah/inertia-form

Weekly Downloads

1

Version

0.1.4

License

ISC

Unpacked Size

987 kB

Total Files

27

Last publish

Collaborators

  • khodakhah