Giter VIP home page Giter VIP logo

catherineisonline / url-shortening-api-frontendmentor Goto Github PK

View Code? Open in Web Editor NEW
11.0 1.0 6.0 1.04 MB

๐Ÿ’ป This is my solution to the URL shortening API landing page challenge on Frontend Mentor.

Home Page: https://catherineisonline.github.io/url-shortening-api-frontendmentor/

License: MIT License

JavaScript 19.35% HTML 19.43% CSS 42.78% TypeScript 18.44%
url-shortener url urlshortener url-shortner url-api shortlink shortly frontend-mentor frontendmentor-challenge frontendmentorchallenge

url-shortening-api-frontendmentor's Introduction

URL shortening API landing page

Solution for a challenge from frontendmentor.io.



About The Project

The goal of this landing page challenge is integration with the shrtcode URL shortening API and playing with browser storage. The challenge is to integrate with the shrtcode API to create shortened URLs and display them like in the designs. You can use any JavaScript framework/library on the front-end such as React or Vue. You also have complete control over which packages you use to do things like make HTTP requests or style your project.

Users should be able to:
1. View the optimal layout depending on their device's screen size. 2. See hover states for all interactive elements on the page.
3. Shorten any valid URL.
4. Copy the shortened link to their clipboard in a single click.
5. Receive an error message when the form is submitted if the input field is empty.
6. See a list of their shortened links, even after refreshing the browser.

I do not have access to the Figma sketch so the design is not pixel perfect.

Built with

  • Semantic HTML5 markup
  • CSS custom properties
  • Flex
  • Grid
  • Desktop-first workflow
  • Shrtco - url shortening API (old)
  • Ulvis - url shortening API (current)

What I learned

Another attempt to play around with API and understand it better. Not very hard as I only need one data from get request. This will be my 3rd small project using API. Working with it is not hard however it does get a little harder when I have to work with dynamic DOM elements. Once again was glad to practice some CSS and eventlisteners. I try not to match the original design as much as I did before as it takes more time and I prefer to spend it mostly on JavaScript.

The hardest part which I never managed to finish is saving the cache after reloading. I tried different ways but I am not getting the final result. I do manage to retrieve the previous data (the input value, for instance) however I am unable to make it visible. I usually use console.log-s to understand what I am doing and it does work, I do retrieve everything I need but I have a hard time displaying it on dynamic elements. The elements stay there after refresh however they are empty. I will for sure get back to this project again!

Contribution

This project serves as a project to show off my personal skills. I do not accept any contributions like pull requests to this project however if you have any suggestions or ideas feel free to message me or submit an idea in the discussions. Otherwise, you are free to fork this project and change it for your own purposes.

Useful resources

  1. Figma - Paste your design image to check the size of containers, width, etc.
  2. Perfect Pixel - Awesome Chrome extension that helps you to match the pixels of the provided design.
  3. Shrtco - url shortening API (old).
  4. Ulvis - url shortening API (current).

Acknowledgments

A big thank you to anyone providing feedback on my solution. It definitely helps to find new ways to code and find easier solutions!

url-shortening-api-frontendmentor's People

Contributors

catherineisonline avatar

Stargazers

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