Skip to content

Instantly share code, notes, and snippets.

View Sllayan's full-sized avatar
🦎
This is a CPU, not an HDD

Shayan Sllayan

🦎
This is a CPU, not an HDD
View GitHub Profile
@Sllayan
Sllayan / README.md
Last active October 14, 2023 13:17
Python(logger): best practice to create a logger function and use it anywhere you need to log

Python

Logging

Best practice to create a logger function and use it anywhere you need to log

log.py : include logging config and function use.py : call example

It is better to create a config file and set the settings of the log.py file in it.

@Sllayan
Sllayan / README.md
Last active October 14, 2023 13:15
Typescript(logger): best practice to create a logger function and use it anywhere you need to log

Typescript

Logging

Best practice to create a logger function and use it anywhere you need to log

log.ts : include logging config and function use.ts : call example

It is better to create a env file and set the settings of the log.ts file in it.

@Sllayan
Sllayan / README.md
Last active November 25, 2023 14:41
Linux : gnome terminal settings backup

Linux

gnome terminal settings backup


Customize your gnome terminal with this file

Open terminal in .txt file directory :

@Sllayan
Sllayan / README.md
Last active October 14, 2023 13:17
Save as file (download in browser) functionality

Typescript

Save File (Download from browser)

Download a file from browser code

@Sllayan
Sllayan / README.md
Last active January 17, 2024 13:44
Manage states in routing between pages in React app

React router state manager

Hook for manage states

get and set state on react router

@Sllayan
Sllayan / README.md
Last active January 26, 2024 16:54
A hook for make a timer

Timer Hook

Timer hook for make a time with trigger

;)

@Sllayan
Sllayan / README.md
Last active January 28, 2024 16:10
Regex for some entry data

Regex

Some practical regex for use

;)

@Sllayan
Sllayan / README.md
Last active January 1, 2025 13:07
my minimal settings vscode to work

Minimal settings for vscode to work

I develop easier with these settings

Customized by me for myself.

You can use it if you want and you can change it for yourself.

@Sllayan
Sllayan / README.md
Last active January 1, 2025 13:06
Simple bash for make a new branch from develop branach

Simple bash for make a branach from develop

Command to run in git directory and make a branch from develop

Customized by me for myself.

@Sllayan
Sllayan / README.md
Last active June 10, 2024 10:46
Python logger (into file)

Python

Logger (save in file)

Best practice to create a logger function and use it anywhere you need to log

main.py : main file to make an example of logger in it. logger.py : log functionality

It is better to create a env file and set the settings of the log.ts file in it.