Sha256: 3f70328e9610d881758f73b273ad64861624d01b46558cebab1c43d32855e49a

Contents?: true

Size: 959 Bytes

Versions: 4

Compression:

Stored size: 959 Bytes

Contents

# Base controller for web pages

module Unsakini
  class WebController < ActionController::Base
    include ActionController::ImplicitRender
    include ActionView::Layouts

    # Renders welcome page
    def index
      @project = 'Unsakini'
      @description = 'Privacy. Confidentiality. Security.'
      @version = VERSION
      @author = 'Adones Pitogo'
      @repository = 'https://github.com/adonespitogo/unsakini'
      @title = "#{@project} | #{@description}"
      @tagline = "Created by and for online activists, information security enthusiasts and government surveillance evaders."
      @keywords = "unsakini, encrypted, bulletin board, BB, ruby, rails"
    end

    # Renders the angular index view when request url is /app/* to enable html5 pushState capability of angularjs
    def app
      gem_root = File.expand_path '../../../..', __FILE__

      render file: "#{gem_root}/public/unsakini/app/index.html", layout: false
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
unsakini-0.0.5 app/controllers/unsakini/web_controller.rb
unsakini-0.0.5.pre.1 app/controllers/unsakini/web_controller.rb
unsakini-0.0.4.pre.1 app/controllers/unsakini/web_controller.rb
unsakini-0.0.4.3 app/controllers/unsakini/web_controller.rb