No commit activity in last 3 years
No release in over 3 years
A gem to setup angular factories
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 1.10
~> 10.0
~> 0

Runtime

 Project Readme

OaAngularSetup

The OaAngularSetup gem will read a swagger compliant API and generate angular factories & controllers.

Note: this gem requires rails

Installation

Add this line to your application's Gemfile:

gem 'oa_angular_setup'

And then execute:

$ bundle

Or install it yourself as:

$ gem install oa_angular_setup

Usage

Simply run:

rake oa_angular_setup:create

To Configure any of the settings run: ruby rails g oa_angular_setup:install or create a new initializer and add the following

  OaAngularSetup.configure do |config|
    # Set the options to what makes sense for you

    #Name of your app (default: 'App') 
    config.app_name = 'App'

    #Create app.js file true/false (default: true)
    config.create_app_js = true 

    #Create factories true/false (default: true)
    config.create_factories = true 

    #Create controllers true/false (default: true)
    config.create_controllers = true

    #The URL where the gem can find your swagger documentation (default: "http://localhost:3000/api/swagger_doc")
    config.swagger_doc_url = "http://localhost:3000/api/swagger_doc"

    #The Destination where the files will be created, starting from your Rails.root . (default: "/public/angular/")
    config.destination = "/public/angular/"
  end

Contributing

Bug reports and pull requests can be made on GitHub at https://github.com/openarcllc/oa_angular_setup.

License

The gem is available as open source under the terms of the MIT License.