GithubHelp home page GithubHelp logo

manishkumar-tudip / ngformiohelper Goto Github PK

View Code? Open in Web Editor NEW

This project forked from formio/ngformiohelper

0.0 1.0 0.0 280 KB

A library to help build Angluar.js applications on top of Form.io.

JavaScript 96.14% HTML 3.86%

ngformiohelper's Introduction

This is a helper module to build Angular.js applications on top of Form.io

Use this helper if you would like to build an Angular.js application that utilizes Form.io authentication and other necessary elements that you need to build an application.

Installation

To install this module, you simply need to use bower and install as follows.

bower install --save ng-formio-helper

We recommend using (WireDep)[https://github.com/taptapship/wiredep] to wire the dependencies into HTML application. If you don't want to use that, then you will need to add the <script> to your page as follows.

<script src="bower_components/ngFormioHelper/dist/ng-formio-helper.js"></script>

Usage

There are several modules that you can use within your application.

  • FormioAuthProvider - This allows you to register the authentication login pages and provide the authenticated and anonymous states.

.config(function(FormioAuthProvider) {

// Set the base url for formio.
FormioAuthProvider.setStates('auth.login', 'home');
FormioAuthProvider.setForceAuth(true);
FormioAuthProvider.register('userLogin', 'user', 'user/login');
FormioAuthProvider.register('customerLogin', 'customer', 'customer/login');
```
  • FormioAuth - You need to run the init() method in order to initialize all of the authentications.

.run(function(FormioAuth) {

// Initialize the Form.io authentication provider.
FormioAuth.init();
```
  • FormioAlerts - Keeps track of all alters that are made within your application. You can add this to your page by adding the following...

{{alert.message}} ```

You can then add new alerts by doing the following.

```

FormioAlerts.addAlert({ type: 'danger', message: 'Your session has expired. Please log in again.' }); ```

ngformiohelper's People

Contributors

travist avatar randallknutson avatar wonder95 avatar

Watchers

Manish Kumar avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.