Coder Social home page Coder Social logo

ni-c0de-mus / uploadcare-widget Goto Github PK

View Code? Open in Web Editor NEW

This project forked from stampsy/uploadcare-widget

0.0 1.0 0.0 2.68 MB

The Uploadcare Widget

Home Page: https://uploadcare.com/

License: MIT License

Ruby 5.22% CoffeeScript 24.61% JavaScript 64.57% CSS 5.61%

uploadcare-widget's Introduction

This is the Uploadcare widget source.

Build Status

Embedding

Add following code to your document's <head>.

<script>
  // Widget settings
  UPLOADCARE_PUBLIC_KEY = 'your_public_key';
</script>
<script src="https://ucarecdn.com/widget/x.y.z/uploadcare/uploadcare-x.y.z.min.js" charset="utf-8"></script>

The official Widget documentation has more information on using the widget itself.

Building Your Own

You need a working Ruby 1.9.3 environment with Bundler.

  • xcode-select --install to install command line tools in OS X

  • sudo gem install bundler to install bundler

  • sudo gem install rake to install rake if missing

  • sudo bundle install to get build dependencies.

  • bundle exec rake js:latest:build to build assets to the pkg/latest directory (with the “latest” suffix).

  • bundle exec rake js:release:build to build assets to the pkg/version folder (with the current version suffix). The version is specified in lib/uploadcare-widget/version.rb.

Development

Clone the repository, and go to test/dummy/. There is a simple Rails app. Run it:

bundle install
bundle update
bundle exec rails server

Open http://0.0.0.0:3000/ . Follow any link. There's going to be a widget or three. Edit code and reload page :-)

Testing

Jasminerice installed under the test/dummy/ Rails app.

To run tests in your browser go to http://0.0.0.0:3000/jasmine.

For more information see jasminerice docs.

guard-jasmine

To run tests in a terminal you must first install phantomjs.

Then you have two options:

  • run bundle exec guard start
  • run bundle exec guard-jasmine

The first one is for continuous tests execution, the second one runs tests just once. Both should be executed from the test/dummy/ directory.

See guard-jasmine docs for more information.

uploadcare-widget's People

Contributors

rpominov avatar disolovyov avatar homm avatar valyagolev avatar dmitry-mukhin avatar ashtuchkin avatar gaearon avatar jerome avatar lfbittencourt avatar slafs avatar

Watchers

James Cloos 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.