Skip to content

ElderJames/vue-sync-form

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Vue 同步POST扩展

Version Author Download GitHub license

简单地使用Vue的扩展方法和 vm.$el api 实现同步submit。原理就是在html页面插入form表单再调用submit方法。

Usage

  1. Use as vue plugin
import Vue from 'vue'
import syncForm from 'vue-sync-form'

//in vue instance
this.$syncForm.postSync("/path", formData);
  1. Use as a class
import { syncForm } from "vue-sync-form";

syncForm.postSync("/test", JSON.parse(this.form));
  1. For more information,please read the sample code, or run the sample with the cmd:
npm run dev

About

Post formdata using a synchronous way for Vue.js

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published