Coder Social home page Coder Social logo

Hello! My name's Yihua 👋

I'm a developer that loves simplifying things. I love breaking down complex problems into simple, easy to understand solutions. I Currently live in Toronto as a software developer. In my spare time, I create courses on software development and mentor new developers.

Yihua Zhang's Projects

lesson-19 icon lesson-19

Now that we have our cart, it's time to create our checkout page. We need a checkout component for the page and our checkout-item component. We're going to connect the page to our cart reducer; we're also going to make a selector to get the total price.

lesson-2 icon lesson-2

Creating our first component, homepage and adding scss to help us with writing our styles

lesson-20 icon lesson-20

We want to be able to remove the item from the cart if the user doesn't want it anymore during checkout so we're going to add the appropriate action and case in our cart reducer.

lesson-21 icon lesson-21

We also want to be able to update the quantity using buttons to the left and right of the number, so we will add the appropriate code to do so.

lesson-22 icon lesson-22

We don't want our users to lose their carts whenever they refresh, so we are going to leverage one of the benefits of redux by persisting our store object in localstorage using redux-persist.

lesson-23 icon lesson-23

We have now created our collection page and converted our shop items data over from an array to an object to better leverage our url parameters! Converting arrays over to objects to store data is called data-normalization and it makes searching for specific elements in our code much easier and efficient!

lesson-24 icon lesson-24

In this section, we are going to introduce our stripe integration and create a stripe button to help us leverage the stripe checkout library. Stripe is an excellent service that allows us to massively simplify our checkout flow, which would otherwise be incredibly complicated.

lesson-25 icon lesson-25

We have removed the redux-logger middleware from our production build!

lesson-26 icon lesson-26

We are now adding styled-components to explore CSS-in-JS. We convert over our Homepage component, Header component and CustomButton component to use styled-components instead of scss.

lesson-26-complete icon lesson-26-complete

In this repository, all our components have been converted to styled-components!

lesson-26.5 icon lesson-26.5

In this lesson, we moved our shop data into firebase. We then pull that data into our application and store it into our shop reducer and push it into our shop page.

lesson-27 icon lesson-27

We've moved our shop data into our firestore database, now we need to modify our application in such a way that considers our data being loaded asynchronously. We have created a WithSpinner HOC as well as modified our shop to initialize the call for data.

lesson-27-complete icon lesson-27-complete

The final version of the application after converting our style files to using styled-components.

lesson-28 icon lesson-28

In this lesson we are using redux-thunk for asynchronous event handling! We have modified our collections-page collections-overview components to use the container pattern to separate their loading logic out of our shop component, and into their own isolated files.

lesson-29 icon lesson-29

We just added redux-saga into our application! The first thing we need to do is convert our fetchCollectionsStartAsync thunk method into a saga instead fo fetch our collections.

lesson-3 icon lesson-3

Going through our folder structure for the project, breaking out homepage component into smaller components

lesson-30 icon lesson-30

In this lesson we are doing a large refactor! We need to convert all our sign in, sign up and authentication persistence checks into sagas. We don't necessarily need to do this for our application, but this is a good way to practice writing sagas in a real world application that may not leverage firebase/firestore or the observer pattern.

lesson-30-signup-saga-exercise icon lesson-30-signup-saga-exercise

In this repo, you will find the code for our project with everything we have done up until now. Make an attempt with all you've learned to create a sign-up flow using the knowledge you have on structuring out saga code!

lesson-31 icon lesson-31

We have separated out our front-end client from our back-end express server that handles our stripe charges. In this section we learn how to write our express backend server as well as syncing our client to request our backend to complete a stripe charge!

lesson-32 icon lesson-32

We have added some media query styles to our styled components, try as an exercise to convert the appropriate pages to be mobile responsive!

lesson-32-complete icon lesson-32-complete

Let's make our code mobile responsive! We wrote some media queries into the appropriate css files and now we have mobile friendly code!

lesson-33 icon lesson-33

We have optimized our client side application to leverage react.lazy for lazy loading our components at the route level, but also using the new Suspense feature so we're able to properly render our now asynchronously loaded components!

lesson-34 icon lesson-34

In this lesson we're adding tests into our application!

lesson-4 icon lesson-4

Adding routing with react-router, then creating new routes for our existing homepage and our new hats page

lesson-5 icon lesson-5

Going over the concept of higher order components through use of the withRouter HOC from react-router-dom.

lesson-6 icon lesson-6

Create collection-preview and collection-item components for the shop page

lesson-7 icon lesson-7

Creating header component to demonstrate where react-router renders our content on the page using <route> component

lesson-8 icon lesson-8

Starting our sign in section by creating a new sign in and sign up page, as well as start creating sign in component.

lesson-9 icon lesson-9

Creating our firebase database and adding the firebase library into our code. Add google sign in and authentication into our application.

lifecycles-lesson icon lifecycles-lesson

Here is our quick CRA application that demonstrates how lifecycles work in class components

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.