Skip to content

stifskere/Portfolio

Repository files navigation

Portfolio

This portfolio is made with NextJs the main idea for this portfolio was because I saw a topographic-like design for my mouse pad, and I decided to make my portfolio around it.

img.png

Building and/or running

This app was made by bootstrapping the create-next-app template, so it contains its development server and build utilities configured for this project specifically.

Use the next dev server to start a local development server in the port 3000

npm run dev

Or you can also run the build tool that's configured to build a static version of this site and place it in the /out directory

npm run build

When you build your own version you should change the .github/workflows folder, and make your own workflows. Since you don't have my poller API access, you might want to create your own poller or deploy it trough FTP somewhere else.

Project dependencies

To install all the dependencies simply run.

npm install

When you configure your project dependencies you will need to clone the .env.example file and fill it with the required environment variables.

  • API_GITHUB_TOKEN: This token is used by the GitHub API all around the project, for the rate widget, the repositories widget, and the gists widget.
  • API_SPOTIFY_AUTH: This token is the general Spotify API token, you can get it in your Spotify developer profile after creating an app.
  • API_SPOTIFY_REFRESH: This token is the one you get when creating an OAuth flow with your app scopes, you need to simulate as if you were a user trying to use the app, which technically you are.

For the Environment variables here are some useful pages I used to help me obtain the tokens.

Spotify polling disclaimer

You may or may not notice that there is a polling system implemented in the site so the Spotify widget can work. The implementation is proxied trough the NextJs back-end, and made to appeal this discussion. The proxy system ensures only a request every 5 seconds is made, which is within the Spotify API rate-limits. Now Spotify is only giving web-socket access to million dollar companies like Discord, which most of us are not.