formtools / api

The Form Tools API.
https://docs.formtools.org/api/
15 stars 16 forks source link

Form Tools API

This repo contains the Form Tools API, providing some methods to interact with and extend Form Tools, such as:

The API documentation is pretty thorough. Please refer to one of the following sections:

API v1.x vs. v2.x

Form Tools 3 was a complete rewrite of the application, including changing the codebase from functional code to object-oriented. The API v2.x was updated for Form Tools 3 compatibility, converting the API into a class.

In terms of functionality, v1.x and v2.x of the API are identical: they (currently) provide the same methods. What's changed has the way you call the API methods.

Examples

The documentation links above contains in-page example code for all the methods, but for something more hands-on check out the examples/ folder in this repo. That contains some simple, bare-bones examples (no CSS!) of some of the API methods that can easily be shown. Other methods such as the form integration methods need additional work to configure Form Tools - so couldn't be included. See the tutorials for further info on them.

Thev1/ folder contains the old Form Tools 2.x compatible API methods (version 1.x of the API); the v2/ folder contains Form Tools 3 compatible API methods (version 2.x of the API). For Form Tools 3 users, please use the v2/ folder examples - v1/ is just provided for people upgrading to Form Tools 3 and want to keep compatibility with their existing API forms and usage.

How to view the examples

Getting help

Please create an issue on this repo.