Creation of a resume using React.js that shows personal information brought in from an API.
First of all, I must say that I am very proud to be able to meet this challenge because I had to prepare myself by watching some of the courses offered by Platzi about Frontend Development with React and JavaScript and now I feel that I have made a lot of progress. I would like to thank Platzi for this opportunity.
* HTML
* CSS
* JavaScript
* React.js
* Webpack
* Jest
To meet this React test, the following objectives were met:
-
- Analyze the structure shown in the image above
- A new git branch is created to work the components
- Create the necessary component files
- Comply with the requirements established in the component tests
- A new component is created to handle the profile photo
- The HTML structure was inserted in each of the components
- Each component field was populated with test information
- Configuration was added to be able to deploy the project in github pages
-
- A new git branch is created to work the styles of the components
- The container for each element is styled.
- A component called "Title" is created that will be called by each component to display a header with the name of each one.
- Some mixins are created that help us to reuse the CSS code and use them easily in the styles of each component.
- The components are styled following the Mobile First methodology
- Media queries are implemented so that the project can be responsive and adaptive for any screen
-
- The getData function receives an argument that is the url of the API and returns a response from the request in JSON format.
- This function can be accessed simply by importing into any document in which you want to occupy the function and can be used by passing any url of any api.
-
- The getData function is imported to the App.jsx container
- The getData function is called by App.jsx. Once you get the data fetched from the API, it is saved in the "data" state using Hooks and all the main components are rendered.
- A component called Loading is implemented that renderes in App.jsx while the information is being searched. This is controlled with a state defined with Hooks called "loading" and a conditional that is in charge of changing the state of "loading" from true to false, and then it renders the other main components.
- The information is passed by props to each component from App.jsx
- The components will be in charge of receiving this information and using it to fill in the fields.
- In those data that are inside an array, the map function was used to traverse it and provide the corresponding information.
-
- The data in the data.json file was changed to real data
- The github and heroku integration was used to deploy the API
npm install
npm run start
npm run server
npm run build
npm run test
npm run lint
You must create a "Fork" of this project, scramble the problems and create a Pull Request to your repository.
If someone wants to add or improve something, you can collaborate directly in this repository: frontend
frontend is released under the license MIT.