Skip to content

abir-islam-z/shortlink-generator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Frontend Mentor - Shortly URL shortening API Challenge solution

This is a solution to the Shortly URL shortening API Challenge challenge on Frontend Mentor. Frontend Mentor challenges help you improve your coding skills by building realistic projects.

Table of contents

Note: Delete this note and update the table of contents based on what sections you keep.

Overview

The challenge

Users are able to:

  • View the optimal layout for the site depending on their device's screen size
  • Shorten any valid URL
  • See a list of their shortened links, even after refreshing the browser
  • Copy the shortened link to their clipboard in a single click
  • Receive an error message when the form is submitted if:
    • The input field is empty

Screenshot

Links

My process

Built with

  • Semantic HTML5 markup
  • CSS custom properties
  • Flexbox
  • Mobile-first workflow
  • React - JS library
  • Styled Components - For styles
  • VsCode - Editor

What I learned

I learned how to use styled components and how to use the clipboard API.

const copyToClipboard = (e) => {
  navigator.clipboard.writeText(e.target.innerText);
};

Continued development

I want to build my own API rather than using the one provided by Frontend Mentor. I also want add authentication to the app so that users can save their links and access them from any device.

Useful resources

Author

Acknowledgments

I want to thank Frontend Mentor for this challenge. I learned a lot from this challenge.