Skip to content

Instantly share code, notes, and snippets.

View adrianhajdin's full-sized avatar

Adrian Hajdin - JS Mastery adrianhajdin

View GitHub Profile
@import url('https://fonts.googleapis.com/css?family=Titillium+Web:400,700,600');
#root {
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
}
.container {
@adrianhajdin
adrianhajdin / index.js
Created July 29, 2022 10:09
I Abandoned Postman for This NEW VS Code Extension | Build, Test & Sell APIs 🤑
import axios from 'axios';
const getCountries = async (currencyCode) => {
try {
const response = await axios.get(`https://restcountries.com/v3.1/currency/${currencyCode}`);
return response.data.map(country => country.name.common);
} catch (error) {
throw new Error(`Unable to get countries that use ${currencyCode}`);
}
@adrianhajdin
adrianhajdin / App.css
Created September 24, 2020 14:21
Gists for the GIF App
body {
background-color: #ee5522;
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 2000 1500'%3E%3Cdefs%3E%3CradialGradient id='a' gradientUnits='objectBoundingBox'%3E%3Cstop offset='0' stop-color='%23FB3'/%3E%3Cstop offset='1' stop-color='%23ee5522'/%3E%3C/radialGradient%3E%3ClinearGradient id='b' gradientUnits='userSpaceOnUse' x1='0' y1='750' x2='1550' y2='750'%3E%3Cstop offset='0' stop-color='%23f7882b'/%3E%3Cstop offset='1' stop-color='%23ee5522'/%3E%3C/linearGradient%3E%3Cpath id='s' fill='url(%23b)' d='M1549.2 51.6c-5.4 99.1-20.2 197.6-44.2 293.6c-24.1 96-57.4 189.4-99.3 278.6c-41.9 89.2-92.4 174.1-150.3 253.3c-58 79.2-123.4 152.6-195.1 219c-71.7 66.4-149.6 125.8-232.2 177.2c-82.7 51.4-170.1 94.7-260.7 129.1c-90.6 34.4-184.4 60-279.5 76.3C192.6 1495 96.1 1502 0 1500c96.1-2.1 191.8-13.3 285.4-33.6c93.6-20.2 185-49.5 272.5-87.2c87.6-37.7 171.3-83.8 249.6-137.3c78.4-53.5 151.5-114.5 217.9-181.7c66.5-67.2 126.4-140.7 178.6-218.9c52.3-78.3 96.9-161.4 13
@adrianhajdin
adrianhajdin / Speechly Config
Last active May 13, 2023 05:48
Speechly Config
category_income = [
Business
Investments
Extra income
Deposits
Lottery
Gifts
Salary
Savings
Rental income
@adrianhajdin
adrianhajdin / Assets
Created April 1, 2022 11:59
React Native - NFT Marketplace Showcase
https://minhaskamal.github.io/DownGit/#/home?url=https://github.com/adrianhajdin/nft-marketplace-showcase/tree/main/src/assets
@adrianhajdin
adrianhajdin / eslintrc.js
Created May 18, 2022 14:38
ESLint Configuration
// eslintrc.js
module.exports = {
env: {
browser: true,
es6: true,
},
extends: [
'plugin:react/recommended',
'airbnb',
],
@adrianhajdin
adrianhajdin / appStyles.js
Created December 20, 2020 15:07
Styles for an Expense Tracker Web Tutorial
import { makeStyles } from '@material-ui/core/styles';
export default makeStyles((theme) => ({
desktop: {
[theme.breakpoints.up('sm')]: {
display: 'none',
},
},
mobile: {
[theme.breakpoints.down('sm')]: {
const axios = require('axios');
// https://fixer.io/
const FIXER_API_KEY = '';
const FIXER_API = `http://data.fixer.io/api/latest?access_key=${FIXER_API_KEY}`;
// https://restcountries.eu
const REST_COUNTRIES_API = `https://restcountries.eu/rest/v2/currency`;
@adrianhajdin
adrianhajdin / categories.js
Created December 20, 2020 15:09
Categories Constants
const incomeColors = ['#123123', '#154731', '#165f40', '#16784f', '#14915f', '#10ac6e', '#0bc77e', '#04e38d', '#00ff9d'];
const expenseColors = ['#b50d12', '#bf2f1f', '#c9452c', '#d3583a', '#dc6a48', '#e57c58', '#ee8d68', '#f79d79', '#ffae8a', '#cc474b', '#f55b5f'];
export const incomeCategories = [
{ type: 'Business', amount: 0, color: incomeColors[0] },
{ type: 'Investments', amount: 0, color: incomeColors[1] },
{ type: 'Extra income', amount: 0, color: incomeColors[2] },
{ type: 'Deposits', amount: 0, color: incomeColors[3] },
{ type: 'Lottery', amount: 0, color: incomeColors[4] },
{ type: 'Gifts', amount: 0, color: incomeColors[5] },
@adrianhajdin
adrianhajdin / package.json
Created March 22, 2022 13:10
Client Side package.json
{
"name": "mern-stack-client",
"version": "0.1.0",
"private": true,
"proxy": "https://memories-project-part4.herokuapp.com/",
"dependencies": {
"@material-ui/core": "^4.9.10",
"@material-ui/icons": "^4.9.1",
"@material-ui/lab": "^4.0.0-alpha.58",
"@testing-library/jest-dom": "^4.2.4",