GithubHelp home page GithubHelp logo

paulsaenzsucre / bookstore Goto Github PK

View Code? Open in Web Editor NEW
8.0 1.0 0.0 2.21 MB

Bookstore is a single page web app that lets users manage a book list. Users can add, edit, and remove books (title and author) from the list. It was coded using React.

Home Page: https://www.paulsaenzsucre.dev/Bookstore/

License: MIT License

HTML 7.61% CSS 20.92% JavaScript 71.47%
booklist books react spa

bookstore's Introduction

banner

Hi 👋, I'm Paul Sáenz Sucre.

A passionate full stack and desktop developer from Perú.

More about me

I am a certified full-stack web developer and a self-taught desktop developer. Currently, I am in the process of refactoring my old desktop application. The application enables users to sell food in a restaurant through a web interface. I utilize standard languages such as HTML5, CSS3, and JavaScript, along with React and Redux libraries for the front-end. For the backend, I employ Ruby on Rails and PostgreSQL.

I have had a passion for computers since my childhood. My father introduced me to coding using a programming language called BASIC. As I grew older, I took it upon myself to learn Assembly language and develop an application called DSKPATCH, which served as a hard disk sector data editor. During this time, I dedicated additional hours after school to teach myself various programming languages, such as Visual Basic 6, Standard Query Language (SQL), PASCAL, JAVA, and C#, as well as object-oriented programming and other programming paradigms.

This extensive experience has equipped me with the ability to design logically coherent algorithms, data structures, and application prototypes during the initial stages of the development process.

I am interested in
  • 📚 I love to read, especially about programming, electronics, embedded devices, design, mathematics, and chess.
  • 🏆 Playing chess brings me great joy.
  • 🎸 In addition, I enjoy playing music. I have taught myself how to play the guitar and bass, and I am currently learning to play the keyboard.
  • 🔧 Furthermore, I have a passion for crafting circuits with Arduino.

Connect with me:

linked in twitter dev medium stack overflow reddit paulsaenzsucre codeforces codeforces youtube

Skills:

Front-end

html5 css3 javascript javascript redux webpack vite

Backend

ruby csharp java php rails rails

Database

postgresql mysql maria db sqlite access maria db

Desktop

csharp java java Visual Basic 6.0

Tools

git GitHub Visual Studio Code Visual Studio eclipse

Misc

arduino illustrator postman

Stats

paulsaenzsucre paulsaenzsucre paulsaenzsucre paulsaenzsucre


Paul Sáenz Sucre logo.

Paul Sáenz Sucre

(back to top)

bookstore's People

Contributors

paulsaenzsucre avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

bookstore's Issues

Write categories actions and reducer.

Write your categories actions and reducer (in /src/redux/categories/categories.js) using the ducks pattern:

  • Define an action type for checking the status.
  • Set the initial state to be an empty array of categories.
  • Export Action Creators for your actions.
  • Write your reducer and export it as default.
    • For the check status action return a string "Under construction".
    • In case of unknown action - return the current state.

Create BooksPage component

Create a component called BooksPage that composes the BookList and AddBookForm components for displaying the Books page.

image

Refactor the App component

Add React Router and set two <Route>s and <Link>s for the app's navigation:

  • Books - the default view
  • Categories

Create Header component

Create a component called Header that composes the Navbar component for displaying the page's header.

image

Style the Add New Book Form UI

Style the add new book form user interface:

  • Style the form title.
  • Style the form inputs.
  • Style the form button.
  • Style the form.
  • Style the container.
  • Arrange elements inside container.

image

Add New Book Feature

In the AddBookForm component, add functionality for "Add new" button click:

  • Import Redux useDispatch.
  • Set title and author in the local React state (NOTE: categories and comments are NOT part of this step).
  • Take the inputs from the state then generate a unique id and add them to an object.
  • Once your new book object is ready to be submitted to Redux store, dispatch the corresponding action.
  • Keep state immutable in the reducer.

Style the App UI

Style the App user interface:

  • Style the app container.
  • Arrange the inside components.

Write book's actions and reducer

Write your book's actions and reducer (in /src/redux/books/books.js) using the ducks pattern.

  • Define action types for adding and removing a book.
  • Set the initial state to be an empty array of books.
  • Export Action Creators for your actions.
  • Write your reducer and export it as default:
    • Define state changes for the actions that you created.
    • In case of unknown action - return the current state.

Book Component

Create a component called Book that composes a CircleProgress component for displaying a single book (receive category, title, author, chapters, currentChapter,).

image

Style the Book Page UI

Style the book page user interface:

  • Style the book page container.
  • Style the separator.
  • Arrange the components inside.

image

Connect Bookstore App to Redux store

Connect the Bookstore app to the Redux store:

  • Import Redux Provider and your store in the main component of your React app.
  • Connect Bookstore app to the Redux store.
  • The default state in books reducer is an array with a few books.
  • Display them in the React components. Make sure that the list of books displays books from Redux store.

Refactor Add Book and Remove Book features

Refactor add book and remove book features to persist changes in the server:

  • Change existing Action Creators, so they return functions.
  • Make changes by using API.
  • Dispatch an action (action type that existed before refactor) that will update the state accordingly.

NOTE: Use fetch or axios with createAsyncThunk for making API calls.

Style the Action Bar UI

Style the action bar user interface:

  • Style the action buttons.
  • Style the button separators.
  • Style the container.

image

Configure the Redux Store

Configure the Redux Store (/src/redux/configureStore.js):

  • Importing the necessary methods from Redux Toolkit.
  • Combine both reducers into a root reducer by using configureStore function.

Style the Categories Page UI

Style the categories page UI:

  • Style the categories page container.
  • Style the check status button.
  • Style the under construction text.

image

Style the Book Card UI

Style the book card user interface:

  • Style the book card container.
  • Arrange the internal components.

image

Style the Book List UI

Style the book list user interface:

  • Style the book list container.
  • Arrange components inside the container.

image

AddBookForm Component

Create a separate component for this form (with inputs for a title and an author [IMPORTANT in the design you can see an input for a category - please replace it with an author.]).

Image

Style the Page Header UI

Style the page header user interface:

  • Style the header container.
  • Style the Bookstore text logo.
  • Style the Navbar
  • Style the user icon.

image

Add Remove Book Feature

In the Booklist component, add a functionality for "Remove" button click:

  • Import Redux useDispatch.
  • Once your book object is ready to be removed from Redux store, dispatch the corresponding action.
  • Keep state immutable in the reducer.

Create Booklist component

Create a component called Booklist that composes Book components for displaying the list of books: should display the list of books (empty at this point but it should be ready for the data) with the Remove button (no functionality yet).

image

Style the Progress Chapter UI

Style the progress chapter user interface:

  • Style the current chapter title.
  • Style the current chapter details.
  • Style the update progress button.

image

Style the Progress Stats UI

Style the progress stats user interface:

  • Style the progress stats container.
  • Style the progress separator.
  • Arrange elements inside container.

image

Add Check Status Feature

In your CategoriesPage component, add a functionality for: "Check status" button click:

  • Import Redux useDispatch.
  • Dispatch the corresponding action.
  • Keep state immutable in the reducer.

Setup Redux-thunk on Bookstore

Instruct Redux to use thunk:

  • Add redux-thunk as a dependency.
  • import redux-thunk and insert its middleware into Redux.

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.