Skip to content

Open source project that is an alternative to the popular Linktree. Written for Nextjs, Gatsbyjs, and Reactjs. Containerized with Docker and GA4 integration.

License

Notifications You must be signed in to change notification settings

ShauryaS/quicklinks

Repository files navigation

Stargazers Forks Contributors Apache License 2.0

Issues Bugs Open Bugs Closed

code style: prettier

Quicklinks-Next

Star this project if you enjoy using it ⭐️

Table of Contents

  1. About
  2. Getting Started
  3. Customizing Data
  4. Adding Theme Templates
  5. Hosting Your Quicklinks
  6. Contributing
  7. License
  8. Star History
  9. Contributors

1. About

This open source project is an alternative to the popular Linktree. Quicklinks is a one-stop website template for people to have quick access to your other socials and important links. Made with Nextjs and containerized with Docker. Google analytics integration is available.

2. Getting Started

Download the Code

Option 1: Clone this repository using the command below:

gh repo clone ShauryaS/quicklinks

Option 2: Download this repository as a zip file.

Option 3: Fork this repository and either clone the forked repository or download the forked repository as a zip.

Once you get the code on your machine, execute git checkout quicklinks-next to ensure you are viewing the Quicklinks code written in Nextjs.

Run the Code in the Dev Env and View in Browser

  1. Open the Terminal and navigate to the project's root directory.

  2. Execute command: npm run dev to view the Quicklinks page in your browser at localhost:3000.

To run the dev env using docker, ensure Docker Desktop is running on your dev machine and execute command: npm run docker-dev. View the Quicklinks page in your browser at localhost:3000.

Example terminal view for running dev Docker container:

npm run docker-dev

The Docker dev env has fast refresh enabled.

To shut down the Docker dev container, execute command: npm run docker-stop.

Example terminal view for stopping dev Docker container:

npm run docker-stop

Run the Code in the Prod Env and View in Browser

  1. Open the Terminal and navigate to the project's root directory.

  2. Build the code by running command: npm run build.

  3. Execute the code by running command: npm start to view the Quicklinks page in your browser at localhost:3000.

To run the dev env using docker, ensure Docker Desktop is running on your dev machine and execute command: npm run docker-prod. View the Quicklinks page in your browser at localhost:3000.

Example terminal view for running prod Docker container:

npm run docker-prod

The Docker prod env DOES NOT have fast refresh enabled.

To shut down the Docker prod container, execute command: npm run docker-stop.

Example terminal view for stopping dev Docker container:

npm run docker-stop

3. Customizing Data

To customize your Quicklinks page, edit the file quicklinksinfo.json. Use the current file as a template/guidline to customize your own Quicklinks page.

Template

{
  "name": "Your Name",
  "image": "/images/default-profile.png",
  "personal_site": "",
  "quicklinks_data": [
    {
      "name": "LinkedIn",
      "link": "https://www.linkedin.com/",
      "image": "https://cdn.jsdelivr.net/npm/simple-icons@v6/icons/linkedin.svg"
    },
    {
      "name": "Instagram",
      "link": "https://www.instagram.com/",
      "image": "https://cdn.jsdelivr.net/npm/simple-icons@v6/icons/instagram.svg"
    },
    {
      "name": "Github",
      "link": "https://github.com/",
      "image": "/icons/github.svg"
    },
    {
      "name": "Medium",
      "link": "https://medium.com/",
      "image": "/icons/medium.svg"
    }
  ],
  "theme": "dark"
}

Personal Information

"name": {your name},
"image": /images/{your image name},
"personal_site": {url to personal/portfolio site or any website},

Fill the value of the name key with your name, the value of the image key with the path pointing to your image, and the value of personal_site key with the url to a personal/portfolio website or any website of your choice. Place all images at the images folder.

QuickLinks Data

"quicklinks_data": [
    {
      "name": {link name},
      "link": {link url},
      "image": {path or url to link logo/icon}
    },
    ...
  ]

Quicklinks data is an array of objects representing a link. Fill the value of the name key with the name of the link, the value of the link key with the url of the link, and the value of the image key with the path or url pointing to the icon for the link.

All icons for each link must be an SVG format. Place all SVG icons for each link at the icons folder.

Theme

"theme": {theme name}

Fill the value of the theme key in the json with the name of the theme that should be applied to Quicklinks. The list of themes can be found in themes.jsx. To determine the string value referring to the theme, check the selectTheme function at themeselector.jsx.

4. Adding Theme Templates

  1. Add new themes at themes.jsx and use previous themes as a template to create/add your own.

  2. After adding the theme, update the selectTheme function in themeselector.jsx to return the new theme depending on a specific string value.

Link to Google Analytics

Linking Quicklinks to Google Analytics is pretty straightforward. Once you create a GA4 Data Stream on the Google Analytics website, find the Measurement ID. There are two ways to link to Google Analytics depending on whether a Docker container is used.

Without Docker Container

Replace all instances of ${process.env.NEXT_PUBLIC_GOOGLE_ANALYTICS} in the code with the GA4 Measurement ID.

With Docker Container

In Dockerfile and Dockerfile.dev, replace instances of G-XXXXXXXXXX with the GA4 Measurement ID.

5. Hosting your Quicklinks

Coming soon.

6. Contributing

There are two main ways of contributing to this project. (Hopefully you have starred the project by now ⭐️)

BECOME A CONTRIBUTOR

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Code up your feature or contribution.
  4. Commit your Changes (git commit -m 'Add some AmazingFeature')
  5. Push to your Branch (git push origin feature/AmazingFeature)
  6. Open a Pull Request

You can read more details about adding a feature in our CONTRIBUTING GUIDELINES.

RAISE AN ISSUE OR REQUEST A FEATURE

7. License

Distributed under the Apache License 2.0. See LICENSE for more information.

8. Star History

Star History Chart

9. Contributors

10. Examples

shaurya's quicklinks

About

Open source project that is an alternative to the popular Linktree. Written for Nextjs, Gatsbyjs, and Reactjs. Containerized with Docker and GA4 integration.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published