Inspired by dannyfritz/commit-message-emoji
See also gitmoji.
Commit type | Emoji |
---|---|
Initial commit | 🎉 :tada: |
Version tag | 🔖 :bookmark: |
New feature | ✨ :sparkles: |
Bugfix | 🐛 :bug: |
// Playground: https://mongoplayground.net/ | |
// Documentation: https://mongoosejs.com/docs/ | |
// Cheatsheet1: https://kb.objectrocket.com/mongo-db/the-mongoose-cheat-sheet-225 | |
// Cheatsheet2: https://github.com/azat-co/cheatsheets/blob/master/mongodb-mongoose/readme.md | |
const {Schema, model, connect} = require("mongoose"); | |
let log = console.log; | |
function connectMongoDb() { |
const { v1: uuid } = require("uuid"); | |
const { ApolloServer, gql, UserInputError } = require("apollo-server"); | |
const mongoose = require("mongoose"); | |
// const { books, authors } = require("./data"); | |
//models of collections in mongodb | |
const BookSchema = require("./models/bookSchema"); | |
const AuthorSchema = require("./models/authorSchema"); |
Inspired by dannyfritz/commit-message-emoji
See also gitmoji.
Commit type | Emoji |
---|---|
Initial commit | 🎉 :tada: |
Version tag | 🔖 :bookmark: |
New feature | ✨ :sparkles: |
Bugfix | 🐛 :bug: |
const theme = { | |
colors: { | |
textPrimary: '#24292e', | |
textSecondary: '#297', | |
primary: '#0366d6', | |
}, | |
fontSizes: { | |
body: 14, | |
subheading: 16, | |
}, |
@echo off | |
SET st3Path=C:\Program Files\Sublime Text 3\sublime_text.exe | |
rem add it for all file types | |
@reg add "HKEY_CLASSES_ROOT\*\shell\Open with Sublime Text 3" /t REG_SZ /v "" /d "Open with Sublime Text 3" /f | |
@reg add "HKEY_CLASSES_ROOT\*\shell\Open with Sublime Text 3" /t REG_EXPAND_SZ /v "Icon" /d "%st3Path%,0" /f | |
@reg add "HKEY_CLASSES_ROOT\*\shell\Open with Sublime Text 3\command" /t REG_SZ /v "" /d "%st3Path% \"%%1\"" /f | |
rem add it for folders | |
@reg add "HKEY_CLASSES_ROOT\Folder\shell\Open with Sublime Text 3" /t REG_SZ /v "" /d "Open with Sublime Text 3" /f |
noExcepttion(() => | |
new Promise((res, rej) => { | |
rej('error occured due to storm'); | |
}) | |
); | |
function noExcepttion(cb) { | |
cb().catch((t) => console.log(`::INFO::NOEXCEPTION:: ${t}`)); | |
}; |
const getMutable = (state) => JSON.parse(JSON.stringify(state)); // This is doer. | |
const mutableState = getMutable(state); | |
mutableState.books[0].section[2] = 'Things to be learned in august.'; | |
mutableState.books[1].section[4] = 'Things to be learned in november.'; | |
dispatch(mutableState); | |
// ---------------------------------------------------------------------------------------------------------- | |
// Antoher simple approach is using closures like immer.js does(but it does some depth comparisons too), for e.g. below is my |
/* `Set Applies` to `www.youtube.com` */ | |
/* URLs on the domain www.youtube.com */ | |
.ytp-chrome-bottom { | |
visibility: hidden; | |
} | |
/* above is for player controls hiding. */ | |
.caption-window.ytp-caption-window-bottom{ | |
margin-bottom: 0px | |
} |
// ctrl+shift+e => Edit Button | |
// ctrl+shift+s => Update Gist Button | |
// ctrl+shift+k => Preview Button | |
// ctrl+shift+; => Write Button | |
// To get keycodes visit: "https://keycode.info/" | |
// To get chrome extension visit: "https://chrome.google.com/webstore/detail/custom-javascript-for-web/poakhlngfciodnhlhhgnaaelnpjljija?hl=en" | |
// BELOW CODE IS TO GET EDIT BUTTON AND REGISTER EVENT HANDLER FOR IT. | |
let elements1 = document.getElementsByClassName("btn btn-sm"); | |
let idEditButtonExists = elements1[0].textContent.includes("Edit"); |
const MyFormComponent = () => (<Form> </Form>)
<Formik> {MyFormComponent} </Formik>`
instead of passing inplicityly passing component as
const FomikComponent = () => (<Formik>{() => (<Form> and other bullshit.. <<<here..refer formik site...>>>)})