Skip to content

Instantly share code, notes, and snippets.

View jaamaalxyz's full-sized avatar
🎯
Focusing

Md. Jamal Uddin jaamaalxyz

🎯
Focusing
View GitHub Profile
$(function() {
function LoadPersons(data) {
// do something with data
}
$.ajax({
type: 'POST',
url: url,
data: JSON.stringify(parameters),
contentType: 'application/json;',
// var
var num = 7
console.log(num) // 7
// let
let age = 23
console.log(age) // 23
// const
const NAME = 'Jamal Uddin'
async function displayData() {
try {
const jamal = axios.get('https://api.github.com/users/jamal-pb95')
console.log(data)
} catch(err) {
console.log(err)
}
}
const aPromise = new Promise((resolve, reject) => {
setTimeout(() => {
if(true) {
resolve('I am here!');
} else {
reject('No! It is an error!');
}
}, 5000)
})
// Example website: https://www.marksandspencer.com
// Rules: Display the sticky header when "add to bag" button is not visible in the browser viewport
// and make it work the same way as the main "add to bag" button functionality.
// CSS send to the head
var css = '#btn-group{display:flex;align-items:center;}#prod-price{margin: 0 20px;font-size:1.5rem;font-weight:bold;}#product-header{visibility:hidden;z-index:99999;position:fixed;top:0;display:flex;flex-direction:row;justify-content:space-around;align-items:center;background: #e4e4e4;width:100%;}';
var head = document.getElementsByTagName('head')[0];
var s = document.createElement('style');
s.setAttribute('type', 'text/css');
/* XL Device :1200px. */
@media (min-width: 1200px) and (max-width: 1500px) {
}
/* LG Device :992px. */
@media (min-width: 992px) and (max-width: 1200px) {
[{"quote": "Life isn’t about getting and having, it’s about giving and being.", "author": "Kevin Kruse"},
{"quote": "Whatever the mind of man can conceive and believe, it can achieve.", "author": "Napoleon Hill"},
{"quote": "Strive not to be a success, but rather to be of value.", "author": "Albert Einstein"},
{"quote": "Two roads diverged in a wood, and I—I took the one less traveled by, And that has made all the difference.", "author": "Robert Frost"},
{"quote": "I attribute my success to this: I never gave or took any excuse.", "author": "Florence Nightingale"},
{"quote": "You miss 100% of the shots you don’t take.", "author": "Wayne Gretzky"},
{"quote": "I’ve missed more than 9000 shots in my career. I’ve lost almost 300 games. 26 times I’ve been trusted to take the game winning shot and missed. I’ve failed over and over and over again in my life. And that is why I succeed.", "author": "Michael Jordan"},
{"quote": "The most difficult thing is the decision to act, the rest is merely tenacity.", "author": "
class App extends React.Component {
state = {
buttons: [
{ label: "AC", value: "ac", id: "clear", type: "reset" },
{ label: "CE", value: "ce", id: "ce", type: "cancel" },
{ label: "%", value: "%", id: "percentage", type: "percent" },
{ label: "÷", value: "/", id: "divide", type: "action" },
{ label: "7", value: "7", id: "seven", type: "number" },
{ label: "8", value: "8", id: "eight", type: "number" },
{ label: "9", value: "9", id: "nine", type: "number" },

{ "files.autoSave": "afterDelay", "files.autoSaveDelay": 100, "editor.minimap.enabled": true, "workbench.statusBar.visible": true, "workbench.activityBar.visible": true,

// Set the default "editor.formatOnSave": true, // Enable per-language