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 🙏

© 2024 – Pkg Stats / Ryan Hefner

autoxloo-form-builder

v1.2.33

Published

Fork of a Super Form Builder (drag & drop) build with VueJS by Seth Phat

Downloads

12

Readme

vue-form-builder

npm version GitHub license img HitCount img

A simple form-builder with drag & drop to help you deal your own form. Less code in development and your site will be more generic, configurable.

Advantages:

  • Less code in development
  • Wide range of APIs
  • Easily to maintain, update later
  • Easily to config your form (drag & drop, control settings)
  • ...

Fully documentation in this Repo's Wiki. Check it out!

Give this repo a ⭐ (star) if you actually like this and will use it for your development :D! Thank you!

The library is still in development, so if you meet any bugs or issues, feel free to open!

Demo Online: http://vue-form-builder.sethphat.com
Demo Project: https://github.com/sethsandaru/demo-vue-form-builder

Technologies/Libraries using

  • Javascript
  • VueJS 2.x
  • Webpack
  • JQuery
  • Bootstrap 4
  • ...

Note: From the version 1.2.0 to above, I don't import bootstrap 4 stylesheet into the bundle, you should include your own bootstrap 4 stylesheet in order to get both of GUI & Template working normally.

Form Builder Structure

  • Template: is where you can config/create/edit your own form. template_config

  • GUI: is where the form will be built by your configuration. gui_config

For more information please visit this Repo's wiki, thanks :D!

How to install?

Run this command to install:

npm i v-form-builder --save

NPMJS: https://www.npmjs.com/package/v-form-builder

Notes:

  • For the best experience, please install the latest version!
  • Please don't install the old version below v1.1.1. Thank you!

How to implement?

Import into your project

1/ Import as global component

import FormBuilder from 'v-form-builder';
Vue.component('FormBuilder', FormBuilder);

2/ Import as single component

import FormBuilder from 'v-form-builder';

export default {
    components: {FormBuilder}
    ...
}

Note: you should have your own Bootstrap 4 stylesheet imported inside your project in order to use the Form Builder normally.

Usage

<template>
    <div>
        // form builder template
        <form-builder type="template"></form-builder>
        
        // form builder gui
        <form-builder type="gui" :form="yourConfigFormObject"></form-builder>
    </div>
</template>

Binding options:

  • type (String):
    • Form Config (Template): template
    • Form GUI: gui
  • form (Object) - for Form GUI Only, where you passing the configuration data and the Form Builder will build the form by your configuration data.

V-Model for Form Builder Template

You can use v-model in Form Builder Template, it'll return to you the form configuration data that you're configurated (object) and also render the old configuration and let you edit/update that configuration.

<template>
    <div>
        <form-builder type="template" v-model="formData"></form-builder>
    </div>
</template>

The form config data would look like this:

{
    sections: [...],
    layout: "...",
    _uniqueId: "..."
}

Ideally, you need to convert that Object to JSON string and then save it in your database :D

V-Model for Form Builder GUI

You can use V-Model to get/set values from your built form.

<template>
    <div>
        <form-builder type="gui" :form="formData" v-model="formValues"></form-builder>
    </div>
</template>

The form values data would look like this:

{
    section_key: {
        control_name_1: "data",
        control_name_2: 123,
        ...
    },
    ...
}

APIs

Please visit this Repo's Wiki.

Release notes

  • Version 1.3.0:
    • Milestone 3 released.
    • Able to validate the form.
    • Able to styling the label (bold, italic, underline).
    • Able to set label position for Section (horizontal or vertical)
    • Fix some bugs
    • Constraints for some Hooks
    • APIs for Validate
  • Version 1.2.1:
    • Fix some minor bugs.
  • Version 1.2.0:
    • Hooks are available now for both Template & GUI.
    • More options for controls, like:
      • Select: Ajax data source (URL)
      • Date Picker: date format
      • Time Picker: time format
    • Update control:
      • Number Control to work properly with the decimal places.
      • Time Picker: change to another time picker with a better APIs + options.
    • Fix a problem that make the Date Picker icon didn't show.
    • Stop import Bootstrap 4 CSS into the bundle.
  • Version 1.1.1:
    • First Release of Vue Form Builder
    • Able to config form & render form by config data.
    • Get/set value for both GUI & Template.

Development milestones

  1. First release - Released in 1.1.1
    • Able to config form (Template)
    • Render form by config data (GUI)
    • Get/set value from GUI
  2. Hook will be available for several events. More options for some controls (like select with ajax data source, date format,...) - Released in 1.2.0
  3. Able to validate the form (required mostly), able to style the label (bold, italic, underline and location (top, left)). Released in 1.3.0
  4. Support formula to calculate inside the form.

Copyright © 2018 by Seth Phat aka Phat Tran Minh!