0.1.0 • Published 3 years ago

reactlib-srigol v0.1.0

Weekly downloads
-
License
-
Repository
-
Last release
3 years ago

Update Create React App Installation Setup

npm i typescript @types/react @types/react-dom @types/node

npm i bootstrap react-bootstrap sass

npm i validator xss

npm i -D enzyme @wojtekmaj/enzyme-adapter-react-17 @types/enzyme jest-enzyme @types/jest

npm i -D @testing-library/jest-dom @testing-library/react @testing-library/user-event

npm i -D web-vitals
// # Setup
import Enzyme from "enzyme";
import Adapter from "@wojtekmaj/enzyme-adapter-react-17";

Enzyme.configure({ adapter: new Adapter() });

// # in App.scss
@import "~bootstrap/scss/bootstrap";


/* istanbul ignore file */
  "scripts": {
    "start": "react-scripts start",
    "build": "react-scripts build",
    "test": "react-scripts test",
    "prodtest": "react-scripts test --watchAll=false",
    "prodcoverage": "npm test -- --coverage --watchAll=false",
    "eject": "react-scripts eject",
    "coverage": "npm test -- --coverage"
  },
sc create AzureAvonService binpath=D:\MSKDemoProjs\AZAgent\vsts-agent-win-x64-2.191.1\run.cmd start=auto
## remotes
origin # default name for remote server
remote Url:
git clone <remote-url>
git remote add <name> <remote-url>
git remote -V # to list remote urls

git fetch
git pull # fetch and merge
git push

fork
# create a copy of a repo in your account
# Use forked copy as remote for changes


git branch -D <branch_name> # to delete local branch with commits (all commit will be lost)
git branch -d <branch_name> # to delete local branch
git branch --all # to list all local and remote branchs
git branch # to all all local branches

git checkout -b <branch_name> # to create a new branch

git push -u origin <branch_name> # to push local branch to remote (on remote it will create new branch)
git push origin <branch_name> # to push local changes to remote (based on code reviews)

git ls-remote # list remote branches

git checkout --track origin/<branch_name> # to setup a local branch to track the remote branch

git rm --cached <filename> # to delete file from git repo
git rm -f <filename> # to delete file from git repo and local filesystem

#### Do not rebase after pushing to remote

git log --oneline # see the branch history in oneline
git merge-base branch1 main # get the original base of the branch1 branch created from main
git rebase -i <commit-sha> # start the rebase from the commit sha
pick
squash
squash

then save

# cherry pick
git cherry-pick <commit sha>