This Poll example appliction allows you to ask your site visitors an unlimited number of questions, from an unlimited number of respondents. You add the web widget snippet in your website and your site is ready to go.
To create your polls you get an admin panel to mannage all your Polls. Every created Poll will generate automaticly a widget snippet code which you can put in a website.
Create a project in your Jexia account. Create a dataset with or without fields with name Polling, then create API key and create a policy.
This app is built using Vue.js, Vuex and Vuetify technologies as well as Jexia JavaScript SDK. Made with Jexia features:
- Admin panel for polls management and reports
- Javascript web widget snippet generator
- Jexia:
- Project integration
- Dataset CRUD operations
- Authentication service
Name | Description | |
---|---|---|
[body-parser] | Node.js body parsing middleware | 📚 |
[cors] | Node.js CORS middleware | 📚 |
[express] | Fast, unopinionated, minimalist web framework | 🎨 |
[jexia-sdk-js] | Awesome Jexia Javascript SDK | 🐝 |
[node-fetch] | A light-weight module that brings window.fetch to node.js | 🛠️ |
[ws] | Simple to use, blazing fast and thoroughly tested websocket client and server for Node.js | 🛠️ |
git clone [email protected]:jexia/pollapp.git
cd pollapp
npm install
1. Create project
2. Create dataset named [questions] with these fields:
[
{
"field_name": "question",
"field_type": "string",
"is_required": "true"
},
{
"field_name": "order",
"field_type": "integer",
"is_required": "true"
},
{
"field_name": "poll_uuid",
"field_type": "string",
"is_required": "true"
},
{
"field_name": "skipped",
"field_type": "boolean",
"is_required": "false"
}
]
3. Create dataset named [answers] with these fields:
[
{
"field_name": "question_uuid",
"field_type": "string",
"is_required": "true"
},
{
"field_name": "answer",
"field_type": "string",
"is_required": "true"
},
{
"field_name": "result",
"field_type": "integer",
"is_required": "true"
},
{
"field_name": "poll_uuid",
"field_type": "string",
"is_required": "true"
}
]
4. Create dataset named [polls] with these fields:
[
{
"field_name": "message",
"field_type": "string",
"is_required": "true"
},
{
"field_name": "name",
"field_type": "string",
"is_required": "true"
}
]
5. Create API-key
6. Create CRUD policy for all users and all datasets
7. Update the code with your host-id, project-id, API-key and API-secret
npm start
npm run build
npm run lint
MIT © jexia