Code Monkey home page Code Monkey logo

showbunny's Introduction


Logo

Showbunny

A place to watch and track your favourite movies and tv shows!

Visit Site (Prior Version) β€” Report Bug β€” Request Feature

Vercel Contributors Issues License

Table Of Contents

About The Project

There are many great streaming sites on the web; however, most of them lacked features I wished were included. I wanted to create a site so amazing that it'll be the last one you ever need.

Built With

This project was built using vanilla HTML, CSS and JavaScript.

Getting Started

To run this project locally, please follow the below steps.

Prerequisites

You will need the following installed on your machine:

Installation

First you will want to clone the repository.

git clone https://github.com/macjabeth/showbunny.git

Then install NPM packages.

npm install

Usage

The default npm scripts are as follows.

{
  "scripts": {
    "dev": "vite",
    "build": "vite build",
    "serve": "vite preview"
  }
}

To start the dev server, type npm run dev into the terminal.

Roadmap

See the open issues for a list of proposed features (and known issues).

Contributing

Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated (and will get you added to the acknowledgements section).

  • If you have suggestions for adding or removing features, feel free to open an issue to discuss it, or directly create a pull request after making any necessary changes.
  • Create individual PRs for each suggestion.
  • Please also read through the Code Of Conduct before posting your first idea.

Creating A Pull Request

  1. Fork the Project
  2. Create your GitFlow Branch (git checkout -b feature/amazing-feature)
  3. Commit your Changes (git commit -m 'Add some amazing-feature')
  4. Push to the Branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

Joining the Community

We have a community on Discord to discuss Showbunny and other topics. Feel free to come join us!

License

Distributed under the MIT License. See LICENSE for more information.

Authors

  • macjabeth - a software engineer passionate about learning new technologies and teaching others to be better developers
  • BabyMaybe - my friendly neighbourhood cat

Acknowledgements

showbunny's People

Contributors

arjitmalik avatar babymaybe avatar bassadin avatar bennetthanna avatar crownedpigeon avatar dreaminfo avatar evmosaic avatar lillian-kodi avatar macjabeth avatar shad-k avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

showbunny's Issues

SyntaxError: Unexpected token S in JSON

We are currently getting an error in the console:

SyntaxError: Unexpected token S in JSON at position 0
    at JSON.parse (<anonymous>)
    at window.onload (app.js:59)

This needs to be tracked down and fixed.

Add styling and data for TV routes

Styling and data should be inspired by the design spec (see README.md).

Tasks

  • Render TV show data
  • Show seasons and episodes
  • Style displayed data for mobile screens
  • Style displayed data for tablet & desktop screens

Simplify pagination

On searches with lots of results the first and last pages can be off the sides of the screen. Maybe find a way to reduce the amount of results (first few, last few, and some ellipsis for instance).

image

Images and icons should be carried over

In the develop branch lies the old version of Showbunny, which includes the necessary images, icons and favicon. These should be copied over and referenced appropriately.

Add semicolons!!!

While semicolons are technically optional in Javascript its good practice to use them for line endings and there are even some weird edge cases where Javascript will actually break if they aren't there. So start getting in the habit of using them now ;)

Implement a Content Security Policy

Is your feature request related to a problem? Please describe.
Having security risks is always a problem. Content Security Policy (CSP) is an added layer of security that helps to detect and mitigate certain types of attacks, including Cross-Site Scripting (XSS) and data injection attacks. These attacks are used for everything from data theft to site defacement to distribute malware.

Describe the solution you'd like
A CSP should be defined as an HTTP header which allows content from 3rd-party sites such as TMDB for images and gstatic for fonts.

Add styling and data for Movie routes

Styling and data should be inspired by the design spec (see README.md).

Tasks

  • Render Movie data
  • Style displayed data for mobile screens
  • Style displayed data for tablet & desktop screens

NPM Audit Issues & Vulnerabilities

Upon installation we are getting:

found 10 vulnerabilities (1 low, 3 moderate, 6 high)

These audit errors need manual review and fixing.

Divide Page into Web Components

Modularity and DRY code is the purpose of this issue. In order to keep things clean, elements like movie/show posters should be turned into Web Components.

Others could be converted as well.

404 errors when loading resources

We are getting the following errors when loading the page:

Failed to load resource: the server responded with a status of 404

This started showing up after adding in the TV show posters. It seems like it is trying to fetch these resources before the poster paths are appended to the web components.

Mobile images served with low resolution

Describe the bug

Image natural dimensions should be proportional to the display size and the pixel ratio to maximize image clarity.

To Reproduce

Steps to reproduce the behavior:

  1. Load site on mobile device
  2. See pixelated/unclear images

Expected behavior

Load the correct image size from the API to sharpen image resolution.

Screenshots

Screen Shot 2021-09-14 at 12 20 58 AM

Desktop view cannot scroll through the lists

Describe the bug

The lists are able to be scroll through on mobile and tablet views, but for desktop users - specifically ones with a mouse - they are unable to scroll to the right or left.

To Reproduce

Steps to reproduce the behavior:

  1. Go to the home page on desktop
  2. Attempt to drag or scroll through one of the lists
  3. See issue

Expected behavior

Users should be able to scroll by clicking nav buttons on the left or right of the list, as seen in other streaming services.

Implementation Examples

Screen Shot 2021-09-13 at 11 26 46 PM

Screen Shot 2021-09-13 at 11 45 59 PM

Screen Shot 2021-09-13 at 11 46 45 PM

Design a bunny-themed favicon

For any artists out there who love bunnies, this is your chance to shine.

Please keep in mind that these icons will be used not only in the browser but for any PWA icons in the future. Including a 512x512 icon is important.

See https://github.com/audreyr/favicon-cheat-sheet for a guide and best practices.

πŸ₯• You will be awarded a tasty carrot for completing this task. πŸ₯•

Media posters are duplicated when navigating between pages

Describe the bug
There is an issue where the media posters are repeating themselves each page refresh.

To Reproduce
Steps to reproduce the behavior:

  1. Click on movies page
  2. Go back to homepage
  3. Scroll through movies list
  4. See that movies have been duplicated in the list

Expected behavior
Only one movie and show should show up. Duplicates should not be present

Additional context
There are a few ways this could be corrected, but the ideal solution would be to keep a cache of results for each request to the API. Then when switching pages, we can clear out existing page data and check the cache before making another API call.

Update Site Manifest

The previous version of Showbunny included updated images and icons (which can be viewed in the master branch).

These changes should be moved over to the rebirth branch and the site.webmanifest should be updated to fix the following console errors.

Manifest: property 'start_url' ignored, URL is invalid.
Manifest: property 'src' ignored, URL is invalid.

Responsive Image Sizes

Instead of coding the image URL as a background, it should use an picture tag with source tags set to appropriate poster sizes so that the image quality is optimized for each device.

Example:

<picture>
  <source media="(max-width: 92px)" srcset="w92.jpg">
  <source media="(max-width: 154px)" srcset="w154.jpg">
  <source media="(max-width: 185px)" srcset="w185.jpg">
  <source media="(max-width: 342px)" srcset="w342.jpg">
  <source media="(max-width: 500px)" srcset="w500.jpg">
  <source media="(max-width: 780px)" srcset="w780.jpg">
  <img src="original.jpg" alt="Poster image">
</picture>

The available poster sizes can be viewed here.
Documentation on responsive images can be found here.

Create info modal

When you click on a search result, it should open a modal window to display more information and streaming options.

  • create basic layout
  • add styling
  • add interactivity

Convert to PWA

There are numerous benefits to this; having native support for mobile devices is enough to make it a worthwhile improvement.

Tasks:

  • Configure the Web App Manifest
  • Create the Manifest icons
  • Add the Service Worker code
  • Set up Service Worker Cache to ensure site works offline

Fix 404 resource errors

We're getting errors when trying to import javascript from the index.html.

Failed to load resource: the server responded with a status of 404

These errors are due to the way Vite is bundling for production, and should be fixed.

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.