autocomplete attr #63 I have updated the doc and completed some stuff. Please tell me if you find some problem. I tried to sort properties alphabetically but it is not yet consistent (some field are not sorted yet).
I will now finish the test for #63
Thanks! I will check it.
I just realized fieldStaticMap is not in the doc...
EDIT : I created the entry, can you fill in information ? https://www.gitbook.com/book/icebob/vueformgenerator/edit#/edit/master/fields/staticmap.md
Hmm, it was a quick test field only. But it stay. I fill the docs, thanks.
:tada: v0.4.1 released
https://github.com/icebob/vue-form-generator/releases/tag/v0.4.1
Sorry about the pressure. If you want I can help with the custom fields if you give me a topo.
It would be good.
For custom fields:
Write some sentences about if you need an extra custom field. you can create it yourself.
Main points:
VueFormGenerator.abstractField as a mixins for your fieldAnd add some code snippet from dev as a sample:
Example custom field: https://github.com/icebob/vue-form-generator/blob/master/dev/fieldAwesome.vue
Register globally: https://github.com/icebob/vue-form-generator/blob/master/dev/app.vue#L44
Use in the schema: https://github.com/icebob/vue-form-generator/blob/master/dev/schema.js#L183
This is very powerful. How about we make it possible to choose which fields to load ? For example Keen UI does that.
You can choose to load all or individual components. That would reduce the size of the plugin (right now it is bigger than Vue.js once build with Webpack).
I think it is not neccessary. Because the code of fields is tiny. Check this webpack stat:

You can see, the code of fields is only 1.8% of the whole size. The full src folder is only 2%.
The big parts is vue, moment, and lodash.
You can check too, if you make a build and drop the stat.json file to https://chrisbateman.github.io/webpack-visualizer/
why is lodash so big ? It seem like we only use some functions from it.
How about we unpack Moment.js ? Make it a dependency of vue form generator ?
For example, I will use Moment.js (and maybe lodash) in my project alongside vfg. Will Webpack understand that there is common chunks (I don't think so because it is minified) ?
After all, using it inside vfg is not magically removing the dependency it have from those libs. It just doesn't allow for optimized bundling later on and space lost for no good reason.
I think, this stats made before Dedupe, so it contains unused parts too. I think it, because stats.json said the full size is 1.2MB, but the bundle size is only ~400kB after build.
In a separated branch we can try to remove these dependencies and use as external deps. But I don't know, how we do that, Because if we set these libs to externals in webpack config, it will try to load from global var. But it won't work if you are try to using vfg from other webpack project. More information: https://webpack.github.io/docs/library-and-externals.html
I'm going to test it. A very modularized version of the app would be a plus.
My goal is:
script tag and it work as expected (like today build).The link you provided give me everything I need to make it work.
EDIT: I opened a new issue for that #67
@icebob can I merge the doc with master ?
https://www.gitbook.com/book/icebob/vueformgenerator/edit#/edit/custom-fields/fields/custom_fields.md
Yes please. Thank you!
how can i provide the schema through json file .