Coder Social home page Coder Social logo

my-website's Introduction

Logo

mojganjafari.ir - v1

The first iteration of mojganjafari.ir built with Nextjs and hosted with Vercel

Vercel Status

🚨 About this repo (please read!)

You can use this code for your own website, but please with attribution 😊.

Please note that the design of the website is inspired from "brittanychiang.com", but didn't copied even a single piece of code from brittanyching repo, However, i built the portfolio from scratch with different technolgoies, like Tailwind CSS and Framer Motion and i added some other functionalities to it, so it might seems the same, but believe me i did a lot of work the code, website and how it works is entirely different!!!!. If you have questions about implementation, please refer to the Next.js DOCS same thing for Tailwind CSS and Framer Motion check out the Documentation, Or you can simply reach to me directly.

I'd like to highlight that the This website can't be reached trick featured on my portfolio is an original idea and not borrowed from any other source. It's intended as a playful element, reflecting my sense of humor. While I acknowledge that it might not be the most user-friendly approach, it's worth mentioning that my portfolio receives an average of 30-10 daily visitors. Through careful observation, I've calculated that the average reaction time is 2 seconds before users realize the playful nature of the message, at which point the content becomes accessible. It's a quirky touch meant to add a lighthearted element to the user experience.


Table of Contents


Description

Without a doubt a portfolio website is a unique way to showcase your work and let others know about yourself. It’s like an evergreen platform for your projects, case studies, and information about you. However, Why why did i choose Next.js? Because it is a React framework with Server-Side Rendering, which is good for SEO (Good for us if we get found on Google, right?).

Also, Next.js helps us build a full back-end & blazing-fast websites along with benefits such as Image optimization.

Why tailwindcss? Because TailwindCSS is a framework which reduces a lot of styling efforts. It has low level CSS classes that you can directly embed into the HTML code.


Technologies & libraries

Since i integrated some of my project into my website i'll i mention most of technologies & libraries that i used.

  • Next.js
  • Nodejs
  • TypeScript
  • Tailwind CSS
  • framer-motion
  • Google API
  • cookie-cutter
  • react-leaflet
  • Vercel Analytics
Note :
You can find the rest of packages in the file /package.json

How To Use

Yes, you can fork this repo. Please give me proper credit by linking back to mojganjafari.ir. Thanks!

πŸ›  Installation & Set Up

  1. Clone the repo CLI

    git clone https://github.com/MojganJ/my-website.git
  2. Install and use the correct version of Node using NVM

    nvm install
  3. Install dependencies

    yarn
  4. (OPTIONAL) : Add .env file to the root project

    touch .env
  1. (OPTIONAL) : Add your Google API key inside .env file.
Note :
not Adding Google API to the project will cause not returning the correct zip code, it might be always "00000"
make sure you enabled Geolocation to this API
    NEXT_PUBLIC_KEY_GOOGLE_API="your API key"
  1. Start the development server

    yarn dev

πŸš€ Building and Running for Production

  1. Generate a full static production build

    yarn build
  2. Preview the site as it will appear once deployed

    yarn run serve

API Description :

Endpoint 1 :

the following endpoint will return a json object contains a bunch of information about the ip address

    /api/userInfoByIP/[IP-Address]

example :

    /api/userInfoByIP/159.89.173.104
Get Request to above endpoint will return the following json data :
    {"zip":"560002","country":"India","countryCode":"IN","region":"KA","regionName":"Karnataka","city":"Bengaluru","datetime":"9/6/2022, 1:24:30 AM","lat":12.9634,"lon":77.5855,"timezone":"Asia/Kolkata","isp":"DigitalOcean, LLC","org":"Digital Ocean","as":"AS14061 DigitalOcean, LLC","query":"159.89.173.104"}
Endpoint 2 :

the following endpoint will return a json object contains the zip code for the latitude and logitude

    "/api/userInfoByLatLon/" + lat + "/" + lon

example :

    /api/userInfoByIP/159.89.173.104
Get Request to above endpoint will return the zipcode of the lat and long provided :
    {"zipcode" : "56998"}
the Response below is returned if the lat and long provided has no zip code in Google maps, like lat & long in positioned in the ocean :
    {"zipcode" : "00000"}
Endpoint 3 :

the following endpoint will return a json object contains "quote" and "author", for SpeedTyping project i displayed only the quote, minLength is considered as the minimum of characters.

    /api/typing/[minLength]
notes :
  • minLength should be between 10 - 300.
  • the returned quote is a chain of
  • i costumized the original Endpoint using The API Route of Nextjs, here is the Original Endpoint.
Original Endpiont :
URL :
    https://api.quotable.io/random?minLength=[minLength]

References

Color Hex
Navy #0a192f #0a192f
Light Navy #112240 #112240
Lightest Navy #233554 #233554
Slate #8892b0 #8892b0
Light Slate #a8b2d1 #a8b2d1
Lightest Slate #ccd6f6 #ccd6f6
White #e6f1ff #e6f1ff
Green #64ffda #64ffda

License

MIT License

Copyright (c) [2022] [Mojgan Jafari]

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.


Author Info

Back To The Top :

my-website's People

Contributors

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