git fetch origin <source-branch>:<new-local-branch>
git checkout <new-local-branch>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /usr/bin/mysqldump -u dbusername -p'dbpassword' dbname > ${HOME}/path/backup.sql |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <img | |
| src={"url"} | |
| alt="" | |
| referrer-policy="no-referrer" | |
| /> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| {"lastUpload":"2020-05-09T22:26:09.895Z","extensionVersion":"v3.4.3"} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * Modern browsers can download files that aren't from same origin this is a workaround to download a remote file | |
| * @param `url` Remote URL for the file to be downloaded | |
| */ | |
| function Download({ url, filename }) { | |
| const [fetching, setFetching] = useState(false); | |
| const [error, setError] = useState(false); | |
| const download = (url, name) => { | |
| if (!url) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * Modern browsers can download files that aren't from same origin this is a workaround to download a remote file | |
| * @param `url` Remote URL for the file to be downloaded | |
| */ | |
| function Download({ url, filename }) { | |
| const [creatingURI, setCreatingURI] = useState(false); | |
| const download = () => { | |
| setCreatingURI(true); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function Example(){ | |
| //Scenerio A | |
| let[name, setUser] = useState('') | |
| let[age, setAge] = useState('') | |
| let[school, setSchool] = useState('') | |
| let[height, setHeight] = useState('') | |
| //Scenerio B |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function bioReducer(state, action) { | |
| switch (action.type) { | |
| case "SET_NAME": | |
| return Object.assign({}, state, { name: action.payload.name }); | |
| case "SET_AGE": | |
| return Object.assign({}, state, { age: action.payload.age }); | |
| default: | |
| throw new Error( | |
| "Your Action Must Have A Type! Consider calling dispatch with an Action" | |
| ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function Bio(){ | |
| let[name, SetName] = useState("Mary Gbebodyee"); | |
| let[age, SetAge] = useState(29); | |
| function setNameHandler(){ | |
| setName("Mary Zlatan") | |
| } | |
| return( | |
| <div> | |
| <h1>{name}</h1> | |
| <h1>{age}</h1> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Symbol.iterator in [] // true | |
| Symbol.iterator in {} // false | |
| Symbol.iterator in "" // true | |
| //.... |
NewerOlder