GithubHelp home page GithubHelp logo

fafafariba / gem-search-ui Goto Github PK

View Code? Open in Web Editor NEW
0.0 2.0 0.0 26.41 MB

App with user interface that connects to RubyGems API and allows user to search for ruby gems and save their favorites

Ruby 51.60% JavaScript 29.34% CSS 10.23% HTML 8.48% CoffeeScript 0.36%

gem-search-ui's Introduction

Gem Search UI

Purpose

To create an app with user interface that connects to RubyGems API using the wrapper gem. Refer to the original prompt for more information.

Instructions

View App browser

Clone this repo.

On the command line:

  • bundle install to set up Rails backend
  • yarn or npm install to set up React frontend
  • rails s to start server
  • yarn start or npm start to launch Webpack

Go to localhost:3000 in browser

Tech and Tools

The app was created using Ruby on Rails, React-Redux, SCSS, Webpack, and Babel.

App Design

React-Redux was selected as the frontend framework for its speed and ability to re-render after a change in state.

Component Hierarchy

<App />
 <Nav/>
 <Favorites />
 <Search />
  <SearchBar />
  <Gems />
   <GemDependencies/>

Store

gem: {
  gem: {
    name: 'faker',
    info: 'Faker, a port of Data::Faker from Perl, is used to easily generate fake data: names, addresses, phone numbers, etc.',
    dependencies: ['i18n']
  errors: null
  }
}

API Request

$.ajax({
 method: 'GET',
 url: 'gems/faker'
})

UI/UX

The app's layout is nearly pixel for pixel identical to the Sketch file. Adjustments were made to the length of the search bar length to better accomodate browswer width and spacing was modified for consistency.

The app is also responsive for optimized tablet and mobile viewing.

Tests

RSpec

From directory, run bundle exec rspec spec/requests/gems_spec.rb

Jest/Enzyme

From directory, run yarn test or npm test. To run individual tests, run yarn test 'testName' i.e. yarn run 'reducers'.

Note: Due to time constraints, only the 'reducers', 'actions', 'util', 'store' tests were completed.

Future Additions

  • Complete Jest/Enzyme component testing
  • Create user friendly submit button to replace magnifying glass when screen size decreases
  • Modify navigation to be more readable for mobile and tablet viewing
  • Add pagination for when gem dependencies or favorites containers overflow
  • Add expiration date to data stored in local storage

gem-search-ui's People

Contributors

fafafariba avatar

Watchers

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