Skip to content

Instantly share code, notes, and snippets.

View suhag10's full-sized avatar
🎯
Focusing

Suhag Ahmed suhag10

🎯
Focusing
View GitHub Profile
@miladd3
miladd3 / remCalc.ts
Last active April 9, 2025 08:01
Javascript px to Rem function
/**
* Converts pixel size to rem and accepts the base as second argument. default base is 16px
*
* @param {number|string} px
* @param {number} base
* @return {string}
*/
const remCalc = (px: number | string, base: number = 16) => {
const tempPx = `${px}`.replace('px', '')
@keithmorris
keithmorris / drive-format-ubuntu.md
Last active June 18, 2025 13:21
Partition, format, and mount a drive on Ubuntu
@rxaviers
rxaviers / gist:7360908
Last active June 22, 2025 03:27
Complete list of github markdown emoji markup

People

:bowtie: :bowtie: πŸ˜„ :smile: πŸ˜† :laughing:
😊 :blush: πŸ˜ƒ :smiley: ☺️ :relaxed:
😏 :smirk: 😍 :heart_eyes: 😘 :kissing_heart:
😚 :kissing_closed_eyes: 😳 :flushed: 😌 :relieved:
πŸ˜† :satisfied: 😁 :grin: πŸ˜‰ :wink:
😜 :stuck_out_tongue_winking_eye: 😝 :stuck_out_tongue_closed_eyes: πŸ˜€ :grinning:
πŸ˜— :kissing: πŸ˜™ :kissing_smiling_eyes: πŸ˜› :stuck_out_tongue:
@mathiasbynens
mathiasbynens / toggleAttr() jQuery plugin
Created February 8, 2010 21:20
toggleAttr() jQuery plugin
/*!
* toggleAttr() jQuery plugin
* @link http://github.com/mathiasbynens/toggleAttr-jQuery-Plugin
* @description Used to toggle selected="selected", disabled="disabled", checked="checked" etc…
* @author Mathias Bynens <http://mathiasbynens.be/>
*/
jQuery.fn.toggleAttr = function(attr) {
return this.each(function() {
var $this = $(this);
$this.attr(attr) ? $this.removeAttr(attr) : $this.attr(attr, attr);