├── .eslintrc.json
├── .github
├── FUNDING.yml
└── workflows
│ ├── deploy.yml
│ ├── firebase-hosting-merge.yml
│ └── firebase-hosting-pull-request.yml
├── .gitignore
├── .storybook
└── main.js
├── .travis.yml
├── .vscode
└── launch.json
├── Mobile device.PNG
├── Performance.PNG
├── README.md
├── _config.yml
├── debug.log
├── email-module-2.gif
├── emailmodule.gif
├── firebase.json
├── music-player-module.gif
├── package.json
├── public
├── favicon.ico
├── index.html
├── logo192.png
├── logo512.png
├── manifest.json
└── robots.txt
├── readme
├── DomElements.md
├── Hooks.md
├── REFERENCE-1.md
├── REFERENCE-2.md
├── REFERENCE-3.md
├── REFERENCE-4.md
├── React-Api.md
├── ReactComponent.md
├── ReactDom.md
├── ReactDomServer.md
├── Reconcillation.md
├── Ref-And-Dom.md
├── RenderProps.md
├── Shallow Renderer
│ └── README.md
├── StrictMode.md
├── SyntheticEvent
│ └── README.md
├── Test Utilities
│ └── README.md
├── TypeCheckingWithProtoTypes.md
├── UnControlledComponent.md
├── hooks
│ ├── README.md
│ ├── api
│ │ └── README.md
│ ├── custom-hook
│ │ └── README.md
│ ├── rules
│ │ └── README.md
│ └── useState
│ │ └── README.md
├── requirements
│ └── README.md
└── test renderer
│ └── README.md
├── src
├── App.css
├── App.test.js
├── App.tsx
├── assets
│ ├── hd.svg
│ ├── image_loading_error.svg
│ ├── loading.svg
│ ├── mailbox.svg
│ ├── night.svg
│ ├── noon.svg
│ └── sunny_day.svg
├── components
│ ├── statefull
│ │ ├── Email
│ │ │ └── Email.tsx
│ │ ├── TodoHome
│ │ │ └── TodoHome.tsx
│ │ ├── TodoImageList
│ │ │ ├── TodoImageList.css
│ │ │ └── TodoImageList.tsx
│ │ └── TodoMusic
│ │ │ └── TodoMusic.tsx
│ └── stateless
│ │ ├── Dialog
│ │ ├── Dialog.css
│ │ └── Dialog.tsx
│ │ ├── EmailItems
│ │ └── EmailItems.tsx
│ │ ├── Greet
│ │ ├── Greet.css
│ │ └── Greet.tsx
│ │ ├── ImageGridList
│ │ ├── ImageGridList.css
│ │ └── ImageGridList.tsx
│ │ ├── ImageListPaging
│ │ └── ImageListPaging.tsx
│ │ ├── Login
│ │ ├── Login.css
│ │ └── Login.tsx
│ │ ├── Logo
│ │ ├── Logo.test.js
│ │ └── Logo.tsx
│ │ ├── Navigation
│ │ ├── Navigation.css
│ │ └── Navigation.tsx
│ │ ├── NotificationSnackBar
│ │ └── NotificationSnackbar.tsx
│ │ ├── NowPlaying
│ │ └── NowPlaying.tsx
│ │ ├── PageNotFound
│ │ ├── PageNotFound.css
│ │ └── PageNotFound.tsx
│ │ ├── RouterNavigation
│ │ └── RouterNavigation.tsx
│ │ ├── ShowEmail
│ │ └── ShowEmail.tsx
│ │ ├── ThemeWidget
│ │ ├── ThemeWidget.css
│ │ └── ThemeWidget.tsx
│ │ ├── TodoAdd
│ │ ├── TodoAdd.css
│ │ └── TodoAdd.tsx
│ │ ├── TodoListContainer
│ │ ├── TodoListContainer.css
│ │ └── TodoListContainer.tsx
│ │ ├── TodoListItem
│ │ ├── TodoListItem.css
│ │ └── TodoListItem.tsx
│ │ └── TodoMusicList
│ │ └── TodoMusicList.tsx
├── context
│ └── ThemeManager.ts
├── error-component
│ └── ErrorComponent.tsx
├── index.css
├── index.tsx
├── interfaces
│ ├── Actions.ts
│ ├── App.ts
│ ├── Dialog.ts
│ ├── EmailAppState.ts
│ ├── EmailItems.ts
│ ├── Greet.ts
│ ├── ImageListItem.ts
│ ├── ImageLoaderInterface.ts
│ ├── Logo.ts
│ ├── MusicItem.ts
│ ├── MusicResult.ts
│ ├── NotificationSnackbar.ts
│ ├── SliderInterface.ts
│ ├── State.ts
│ ├── Themes.ts
│ ├── TodoHome.ts
│ ├── TodoList.ts
│ ├── TodoListItem.ts
│ ├── login.interface.ts
│ └── routeconfig..ts
├── list.svg
├── logo.svg
├── react-app-env.d.ts
├── serviceWorker.ts
├── shared
│ ├── CustomSvg
│ │ ├── CustomSvg.css
│ │ └── CustomSvg.tsx
│ ├── Drawer
│ │ └── NavDrawer.tsx
│ ├── ImageLoading.tsx
│ ├── InfiniteScrolling
│ │ └── InfiniteScollingContainer.tsx
│ ├── Loader
│ │ └── Loader.tsx
│ └── PrettoSlider.tsx
├── store
│ ├── actions
│ │ ├── email.action.ts
│ │ ├── login.action.ts
│ │ ├── music.action.ts
│ │ ├── notification.action.ts
│ │ └── todo.action.ts
│ ├── index.ts
│ ├── reducers
│ │ ├── email.reducer.ts
│ │ ├── login.reducer.ts
│ │ ├── music.reducer.ts
│ │ ├── notification.reducer.ts
│ │ └── todo.reducer.ts
│ └── selectors
│ │ ├── email.selector.ts
│ │ ├── login.selector.ts
│ │ ├── music.selector.ts
│ │ ├── notification.selector.ts
│ │ └── todo.selector.ts
├── stories
│ ├── 0-Welcome.stories.js
│ └── 1-Button.stories.js
└── utils
│ ├── core.util.spec.ts
│ ├── core.utils.ts
│ ├── http.util.ts
│ ├── logger.util.ts
│ └── routes.util.tsx
├── tsconfig.json
├── typings.d.ts
└── yarn.lock
/.eslintrc.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": ["react-app", "plugin:jsx-a11y/recommended"]
3 | }
4 |
--------------------------------------------------------------------------------
/.github/FUNDING.yml:
--------------------------------------------------------------------------------
1 | # These are supported funding model platforms
2 |
3 | github: [narendrasinghrathore]
4 | custom: ["https://paypal.me/frontendadvocate?locale.x=en_GB"]
5 |
--------------------------------------------------------------------------------
/.github/workflows/deploy.yml:
--------------------------------------------------------------------------------
1 | name: Build and Deploy
2 | on:
3 | push:
4 | branches:
5 | - master
6 |
7 | jobs:
8 | build:
9 | name: Build
10 | runs-on: ubuntu-latest
11 | steps:
12 | - name: Checkout Repo
13 | uses: actions/checkout@master
14 | - name: Install Dependencies
15 | run: npm install
16 | - name: Build
17 | run: npm run build
18 | - name: Archive Production Artifact
19 | uses: actions/upload-artifact@master
20 | with:
21 | name: build
22 | path: build
23 | deploy:
24 | name: Deploy
25 | needs: build
26 | runs-on: ubuntu-latest
27 | steps:
28 | - name: Checkout Repo
29 | uses: actions/checkout@master
30 | - name: Download Artifact
31 | uses: actions/download-artifact@master
32 | with:
33 | name: build
34 | path: build
35 | - name: Deploy to Firebase
36 | uses: w9jds/firebase-action@master
37 | with:
38 | args: deploy --only hosting
39 | env:
40 | FIREBASE_TOKEN: ${{ secrets.FIREBASE_TOKEN }}
--------------------------------------------------------------------------------
/.github/workflows/firebase-hosting-merge.yml:
--------------------------------------------------------------------------------
1 | # This file was auto-generated by the Firebase CLI
2 | # https://github.com/firebase/firebase-tools
3 |
4 | name: Deploy to Firebase Hosting on merge
5 | 'on':
6 | push:
7 | branches:
8 | - master
9 | jobs:
10 | build_and_deploy:
11 | runs-on: ubuntu-latest
12 | steps:
13 | - uses: actions/checkout@v2
14 | - run: npm i && npm run build
15 | - uses: FirebaseExtended/action-hosting-deploy@v0
16 | with:
17 | repoToken: '${{ secrets.GITHUB_TOKEN }}'
18 | firebaseServiceAccount: '${{ secrets.FIREBASE_SERVICE_ACCOUNT_APPTODOREACT }}'
19 | channelId: live
20 | projectId: apptodoreact
21 | env:
22 | FIREBASE_CLI_PREVIEWS: hostingchannels
23 |
--------------------------------------------------------------------------------
/.github/workflows/firebase-hosting-pull-request.yml:
--------------------------------------------------------------------------------
1 | # This file was auto-generated by the Firebase CLI
2 | # https://github.com/firebase/firebase-tools
3 |
4 | name: Deploy to Firebase Hosting on PR
5 | 'on': pull_request
6 | jobs:
7 | build_and_preview:
8 | runs-on: ubuntu-latest
9 | steps:
10 | - uses: actions/checkout@v2
11 | - run: npm i && npm run build
12 | - uses: FirebaseExtended/action-hosting-deploy@v0
13 | with:
14 | repoToken: '${{ secrets.GITHUB_TOKEN }}'
15 | firebaseServiceAccount: '${{ secrets.FIREBASE_SERVICE_ACCOUNT_APPTODOREACT }}'
16 | projectId: apptodoreact
17 | env:
18 | FIREBASE_CLI_PREVIEWS: hostingchannels
19 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
2 |
3 | # dependencies
4 | /node_modules
5 | /.pnp
6 | .pnp.js
7 |
8 | # testing
9 | /coverage
10 |
11 | # production
12 | /build
13 |
14 | # misc
15 | .DS_Store
16 | .env.local
17 | .env.development.local
18 | .env.test.local
19 | .env.production.local
20 |
21 | npm-debug.log*
22 | yarn-debug.log*
23 | yarn-error.log*
24 | .firebaserc
25 | .firebase/hosting.YnVpbGQ.cache
26 |
--------------------------------------------------------------------------------
/.storybook/main.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | stories: ['../src/**/*.stories.js'],
3 | addons: [
4 | '@storybook/preset-create-react-app',
5 | '@storybook/addon-actions',
6 | '@storybook/addon-links',
7 | ],
8 | };
9 |
--------------------------------------------------------------------------------
/.travis.yml:
--------------------------------------------------------------------------------
1 | language: node_js
2 | node_js:
3 | - "10.16.3"
4 | script:
5 | - echo "Deploy!!"
6 | - npm install
7 | - npm run build
8 | install:
9 | - npm install -g firebase-tools
10 |
11 | after_success:
12 | - firebase deploy --project apptodoreact --token $FIREBASE_TOKEN
13 |
--------------------------------------------------------------------------------
/.vscode/launch.json:
--------------------------------------------------------------------------------
1 | {
2 | // Use IntelliSense to learn about possible attributes.
3 | // Hover to view descriptions of existing attributes.
4 | // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
5 | "version": "0.2.0",
6 | "configurations": [
7 | {
8 | "type": "chrome",
9 | "request": "launch",
10 | "name": "Launch Chrome against localhost",
11 | "url": "http://localhost:3000",
12 | "webRoot": "${workspaceFolder}"
13 | }
14 | ]
15 | }
--------------------------------------------------------------------------------
/Mobile device.PNG:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/narendrasinghrathore/todo-app-react/dff208df6b8e99d7b65e36e2c4302faca4248629/Mobile device.PNG
--------------------------------------------------------------------------------
/Performance.PNG:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/narendrasinghrathore/todo-app-react/dff208df6b8e99d7b65e36e2c4302faca4248629/Performance.PNG
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 |
2 | [](https://travis-ci.org/narendrasinghrathore/todo-app-react)
3 |
4 | ## Desktop Performance:
5 |
6 |
7 |
8 |
9 | ## Email module:
10 |
11 |
12 |
13 |
14 | ## Music Player module:
15 |
16 |
17 |
18 |
19 |
20 |
21 | ## Mobile View:
22 |
23 |
24 |
25 | ## Application covers:
26 |
27 | 1. Lazy loading components
28 | 2. Nested routing
29 | 3. Re-Usability of components
30 | 4. Stateful and Stateless component architecture
31 | 5. Async call using axios
32 | 6. Accessibility
33 | 7. Best practices
34 | 8. Performance
35 | 9. Suspense
36 | 10. React-Redux
37 | 11. Parameter based routing i.e. parameter and query based
38 | 12. React hooks i.e. useState and useEffect
39 | 13. Function based components using react hooks
40 | 14. Intersection Observer API
41 |
42 | ## Implementations
43 | This section contains the scenario we require and how we achieve them.
44 |
45 | 1. Dynamic background color in `
57 | Open [http://localhost:3000](http://localhost:3000) to view it in the browser.
58 |
59 | The page will reload if you make edits.
60 |
61 | You will also see any lint errors in the console.
62 |
63 | ### `npm test`
64 | Launches the test runner in the interactive watch mode.
65 |
66 | See the section about [running tests](https://facebook.github.io/create-react-app/docs/running-tests) for more information.
67 |
68 | ### `npm run build`
69 | Builds the app for production to the `build` folder.
70 | It correctly bundles React in production mode and optimizes the build for the best performance.
71 |
72 | The build is minified and the filenames include the hashes.
73 | Your app is ready to be deployed!
74 |
75 | See the section about [deployment](https://facebook.github.io/create-react-app/docs/deployment) for more information.
76 |
77 | ### `npm run eject`
78 |
79 | **Note: this is a one-way operation. Once you `eject`, you can’t go back!**
80 |
81 | If you aren’t satisfied with the build tool and configuration choices, you can `eject` at any time. This command will remove the single build dependency from your project.
82 |
83 | Instead, it will copy all the configuration files and the transitive dependencies (Webpack, Babel, ESLint, etc) right into your project so you have full control over them. All of the commands except `eject` will still work, but they will point to the copied scripts so you can tweak them. At this point you’re on your own.
84 |
85 | You don’t have to ever use `eject`. The curated feature set is suitable for small and middle deployments, and you shouldn’t feel obligated to use this feature. However we understand that this tool wouldn’t be useful if you couldn’t customize it when you are ready for it.
86 |
87 | ## Learn More
88 | You can learn more in the [Create React App documentation](https://facebook.github.io/create-react-app/docs/getting-started).
89 |
90 | To learn React, check out the [React documentation](https://reactjs.org/).
91 |
92 | ### Code Splitting
93 | This section has moved here: https://facebook.github.io/create-react-app/docs/code-splitting
94 | ### Analyzing the Bundle Size
95 | This section has moved here: https://facebook.github.io/create-react-app/docs/analyzing-the-bundle-size
96 | ### Making a Progressive Web App
97 | This section has moved here: https://facebook.github.io/create-react-app/docs/making-a-progressive-web-app
98 | ### Advanced Configuration
99 | This section has moved here: https://facebook.github.io/create-react-app/docs/advanced-configuration
100 | ### Deployment
101 | This section has moved here: https://facebook.github.io/create-react-app/docs/deployment
102 | ### `npm run build` fails to minify
103 | This section has moved here: https://facebook.github.io/create-react-app/docs/troubleshooting#npm-run-build-fails-to-minify
104 |
--------------------------------------------------------------------------------
/_config.yml:
--------------------------------------------------------------------------------
1 | theme: jekyll-theme-minimal
--------------------------------------------------------------------------------
/debug.log:
--------------------------------------------------------------------------------
1 | [0124/102223.569:ERROR:registration_protocol_win.cc(84)] TransactNamedPipe: The pipe has been ended. (0x6D)
2 | [0206/104832.674:ERROR:registration_protocol_win.cc(84)] TransactNamedPipe: The pipe has been ended. (0x6D)
3 | [0207/074348.559:ERROR:registration_protocol_win.cc(84)] TransactNamedPipe: The pipe has been ended. (0x6D)
4 | [0208/074631.857:ERROR:registration_protocol_win.cc(84)] TransactNamedPipe: The pipe has been ended. (0x6D)
5 | [0213/133416.316:ERROR:registration_protocol_win.cc(84)] TransactNamedPipe: The pipe has been ended. (0x6D)
6 | [0213/181538.912:ERROR:registration_protocol_win.cc(84)] TransactNamedPipe: The pipe has been ended. (0x6D)
7 | [0217/134547.793:ERROR:registration_protocol_win.cc(84)] TransactNamedPipe: The pipe has been ended. (0x6D)
8 | [0218/110613.817:ERROR:registration_protocol_win.cc(84)] TransactNamedPipe: The pipe has been ended. (0x6D)
9 | [0218/155658.550:ERROR:registration_protocol_win.cc(84)] TransactNamedPipe: The pipe has been ended. (0x6D)
10 |
--------------------------------------------------------------------------------
/email-module-2.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/narendrasinghrathore/todo-app-react/dff208df6b8e99d7b65e36e2c4302faca4248629/email-module-2.gif
--------------------------------------------------------------------------------
/emailmodule.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/narendrasinghrathore/todo-app-react/dff208df6b8e99d7b65e36e2c4302faca4248629/emailmodule.gif
--------------------------------------------------------------------------------
/firebase.json:
--------------------------------------------------------------------------------
1 | {
2 | "hosting": {
3 | "public": "build",
4 | "ignore": [
5 | "firebase.json",
6 | "**/.*",
7 | "**/node_modules/**"
8 | ],
9 | "rewrites": [
10 | {
11 | "source": "**",
12 | "destination": "/index.html"
13 | }
14 | ]
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/music-player-module.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/narendrasinghrathore/todo-app-react/dff208df6b8e99d7b65e36e2c4302faca4248629/music-player-module.gif
--------------------------------------------------------------------------------
/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "todo-app-react",
3 | "version": "0.1.0",
4 | "private": true,
5 | "dependencies": {
6 | "@material-ui/core": "^4.8.3",
7 | "@material-ui/icons": "^4.5.1",
8 | "@material-ui/lab": "^4.0.0-alpha.39",
9 | "@reduxjs/toolkit": "^1.2.1",
10 | "@types/node": "^13.1.6",
11 | "@types/react": "^16.9.17",
12 | "@types/react-dom": "^16.9.4",
13 | "@types/react-redux": "^7.1.5",
14 | "@types/react-router-dom": "^5.1.3",
15 | "@types/react-window": "^1.8.1",
16 | "@types/styled-components": "^4.4.2",
17 | "axios": "^0.21.1",
18 | "react": "^16.12.0",
19 | "react-dom": "^16.12.0",
20 | "react-redux": "^7.1.3",
21 | "react-router-dom": "^5.1.2",
22 | "react-scripts": "^4.0.3",
23 | "react-spring": "^8.0.27",
24 | "react-window": "^1.8.5",
25 | "redux": "^4.0.5",
26 | "redux-thunk": "^2.3.0",
27 | "source-map-explorer": "^2.2.2",
28 | "styled-components": "^4.4.1",
29 | "typescript": "^3.7.4"
30 | },
31 | "scripts": {
32 | "start": "react-scripts start",
33 | "build": "react-scripts build",
34 | "test": "react-scripts test",
35 | "eject": "react-scripts eject",
36 | "analyze": "source-map-explorer 'build/static/js/*.js'",
37 | "storybook": "start-storybook -p 9009 -s public",
38 | "build-storybook": "build-storybook -s public"
39 | },
40 | "eslintConfig": {
41 | "extends": "react-app"
42 | },
43 | "browserslist": {
44 | "production": [
45 | ">0.2%",
46 | "not dead",
47 | "not op_mini all"
48 | ],
49 | "development": [
50 | "last 1 chrome version",
51 | "last 1 firefox version",
52 | "last 1 safari version"
53 | ]
54 | },
55 | "devDependencies": {
56 | "@babel/plugin-proposal-optional-chaining": "^7.8.0",
57 | "@storybook/addon-actions": "^5.3.13",
58 | "@storybook/addon-links": "^5.3.13",
59 | "@storybook/addons": "^5.3.13",
60 | "@storybook/preset-create-react-app": "^1.5.2",
61 | "@storybook/react": "^5.3.13",
62 | "eslint-plugin-react-hooks": "^2.3.0",
63 | "redux-devtools-extension": "^2.13.8"
64 | }
65 | }
66 |
--------------------------------------------------------------------------------
/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/narendrasinghrathore/todo-app-react/dff208df6b8e99d7b65e36e2c4302faca4248629/public/favicon.ico
--------------------------------------------------------------------------------
/public/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
You clicked {count} times
14 | 17 |