https://github.com/ericadamski/formiql
📝 A GraphQL like interface for form generation
https://github.com/ericadamski/formiql
Last synced: 3 months ago
JSON representation
📝 A GraphQL like interface for form generation
- Host: GitHub
- URL: https://github.com/ericadamski/formiql
- Owner: ericadamski
- License: mit
- Created: 2018-06-11T11:55:19.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2018-06-11T13:03:02.000Z (almost 7 years ago)
- Last Synced: 2025-01-06T09:45:40.271Z (5 months ago)
- Size: 2.93 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# formiql
📝 A GraphQL like interface for form generation```javascript
import gql from 'graphql-tag';
import Formiql from 'formiql';const typeDefs = [
gql`
{
type User {
id: ID!
name: String
birthday: Date # Formiql Custom Type
password: Password # Formiql Custom Type
username: String
}
}
`
];const resolvers = { /* optional, defaults are Ant Design */
input: {
string,
int,
float,
/* Custom Formiql Types */
dollar,
decimal,
phone,
email,
date,
password,
},
textarea,
select,
option,
button: {
cancel,
submit,
radio
},
toggle,
}
};class Main {
render() {
return (
console.log(data)}
type="User"
/>
)
}
}
```