GithubHelp home page GithubHelp logo

rails_wink's Introduction

Wink (for Rails)

About

We got tired of asking people to send us their browser information, screen size, and plugins... so we made it easier for everybody.
Wink grabs a snapshot of the current browser and sends it away.

Please fork and make it better!

This was originally implemented for PHP by Denim & Steel: https://github.com/denimandsteel/wink

##Installation Add gem 'rails_wink' to your Gemfile.

Generate the wink.yml configuration file with rails g rails_wink:config.
Edit the values to point to your support/bug tracking email address.

Mount the engine in your Rails application's config/routes.rb, like this:

Rails.application.routes.draw do

  # Mount the engine at /wink
  mount RailsWink::Engine => '/wink', :as => 'wink'

end

Run your application, and visit /wink.

You can now do cool things like link_to 'Report a Bug', wink.root_url in your application's views.

##License MIT License
Copyright (C) 2012 Darryl Pogue

rails_wink's People

Contributors

dpogue avatar

Watchers

James Cloos avatar  avatar

rails_wink's Issues

Catch JSON Exceptions

If a spambot fills out the Modernizr textarea with link spam, the JSON parser fails and raises an exception.

We should catch this exception.

Rewrite as Rack Plugin?

The original PHP script is a single file, and fairly lightweight. Comparatively, this Rails engine feels massive (although it does have some extra stuff like config files).

I'm interested if this sort of thing could be implemented as a plugin for Rack, which should be lighter and faster than the current engine.

Unfortunately, I don't have much knowledge of Rack (which is something I keep meaning to read up about), so I'm not in a position to be able to do this.

Off the top of my head, sending emails is the only part I'm not entirely sure Rack could handle, but the worst case scenario is that we'd need to drop down to the Mail gem directly.

Include JSON2 for people without native JSON parsing

This includes older iOS versions and older version of IE (below IE8).

I really hate pulling in a library that isn't necessary for most people (with browsers that already support JSON), so I'll probably hold off doing this until someone needs it.

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.