express-formgen

0.1.1 • Public • Published

express-formgen

img Build Status

What is it?

What express-formgen does, is generate forms so you only have to input simple data to generate complex forms. Primarily designed for login, register and contact forms. The config is very easy to learn!

Installation and tests

install with npm: npm i --save express-formgen
test with npm: npm test

Example

app.js:

const app = require('express')();
const eform = require('express-formgen');
const cfg = require('./config');

eform(cfg)

app.use('/', eform.router);

app.listen(8080)

config.js:

module.exports = {
    title: "Login",
    action: "",
    method: "post",
    fields: [
        {
            type: "text",
            placeholder: "username",
            name: "username"
        },
        {
            type: "password",
            placeholder: "password",
            name: "password"
        }
    ]
};

Package Sidebar

Install

npm i express-formgen

Weekly Downloads

0

Version

0.1.1

License

MIT

Unpacked Size

17.4 kB

Total Files

13

Last publish

Collaborators

  • dninja21