Giter VIP home page Giter VIP logo

bookmarkingtool's Introduction

README

This project is a coding challenge provided by AlphaSights. This app allows a user to save their bookmarks to a SQLite database, these bookmarks are then viewed based on their domain.

The bootflat framework is used, the source code for the bootflat-rails gem can be found here: github.com/zakelfassi/Bootflat-Rails

Setup

To install and run this project:

  1. git clone github.com/dfudger/BookmarkingTool.git

  2. cd BookmarkingTool/

  3. bundle install

  4. rake db:migrate

  5. rails server

Future Features

  • URL to be parsed to extract domain, due to time, the user enters the domain manually.

  • Add validation for the form, before added to the databases

  • Delete a bookmark

  • Edit a bookmark

  • Would be nice to have quick creation and view the top sites on the homepage

  • Shortening the url, using tinyurl

  • Parse the page title from the url

  • Filter the bookmarks based on some data

    • Note: This could be done using and sql query where the user enters the text, and chooses if they would like to filter the title, domain, tags, etc.

  • Create a generic filter module - Will need to learn how to do this.

Bugs

No known bugs.

Documentation

Requirements

  • Enter a URL and tags and the bookmark is created

  • The bookmark should be modeled as belonging to a site.

  • The URL needs to be parsed to extract the domain

    • If a site corresponding to that domain doesn’t exist in the database then it must be created.

  • When a bookmark is created:

    • It is attached to a corresponding site

    • It has tags

    • It could also have shortening e.g using tinyurl, also if it pulled in the URL to get the page title

    • Further meta data that would be cool!

  • In the interface, bookmarks visually grouped by a site

    • Viewing an actual bookmark should display:

      • URL

      • Tags

      • Also title, shortening if applicable

Advanced Portion

OPTION ONE

  • Be able to search bookmarks and sites based on any of my data that I have stored

    • No 3rd party free text search stuff here please

  • Extract this search into some kind of generic search module

    • No plugins or free text search engines here please

    • Basically I want to be able to search all the fields (SQL LIKE) of any model. This will give me instant search functionality with a nice clean API to any model I choose to mix it into.

    • Note: This is a contrived example and in real life you are likely to use a free text search gem but I am looking for some understanding of meta programming, API design, and a bit more advanced Ruby than that required for the previous points.

OPTION TWO

  • Filter bookmarks visible on the page based on any data that I have stored

    • i.e. I type in some characters in the filter field and bookmarks with no matches are instantly hidden.

    • Please do not use any existing JS plugins here.

  • Extract client-side filter into some kind of a generic filter module.

    • Be able to reuse this JavaScript/CoffeeScript module in a different application

    • A nice and clean API to integrate and configure it would be nice.

    • If needed, you may define requirements for applications that are going to use your module, e.g. an application has to provide HTML data-filterable attributes for filtering and class attributes denoting filterable units.

Models

Bookmark: url, title, description, site_id

Site: title, url, description, bookmarks (1 - *)

Tags: title

Bookmark_Tags: bookmark id, tags id

Each model has a controller. Using, CRUD, I can attach views to the controller to get info and display info.

UPDATE: This ended up changing, for the many-to-many and one-to-many, reconrd associations were used.

General Steps:

  1. Complete a Rails tutorial

  2. Work out the models

  3. Generate each model (then do a db migrate)

  4. Add models to routes file (resources)

  5. Add a controller method and view for each action ( like list posts )

  6. Create forms for each view (try to use partials)

  7. Work on making the views more usable

  8. Parse the url to get domain

  9. Shorten the url

See use cases for details actions.

Use Cases

  • Go to homepage

  • View a list of sites and bookmarks

  • Create a bookmark

  • View a bookmark

  • Edit a bookmark

  • Delete a bookmark

  • Create a bookmark with an existing site

  • Create a bookmark with tags

  • Create a bookmark with no tags

  • View a site

bookmarkingtool's People

Contributors

dfudger avatar

Watchers

 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.