How to manipulate data with JavaScript in the browser
Table of Contents
Getting starting with the programming Language JavaScript to manipulate array, objects, functions etc...
- Be sure to have a GitHub account.
If not, you should create a GitHub account then add your ssh to your github profile for a simpler authentication.
- Fork the repository via
github
- Clone your forked repository
https://github.com/YOUR_USERNAME/clear-fashion
❯ cd /path/to/workspace
❯ git clone git@github.com:YOUR_USERNAME/clear-fashion.git
- Open the entry point ../client/v1/index.html in your browser (that loads the
index.js
file)
# macos cli
❯ open client/v1/index.html
# linux cli
❯ xdg-open client/v1/index.html
# or by double-clicking in your browser files
- Check the ouput in your browser console (Use
Ctrl + Shift + J
orCmd + Opt + J
to focus to your console devtools)
- Solve each
TODO
inside ../client/v1/index.js file with JavaScript
- Once a TODO is solved, commit your modification:
❯ cd /path/to/workspace/clear-fashion
❯ git add -A && git commit -m "feat(lowest): compute number of products"
(why following a commit message convention?)
- Commit early, commit often
- Don't forget to push before the end of the workshop
❯ git push origin master
Note: if you catch an error about authentication, add your ssh to your github profile.
- Check that your codebase works by checking the console output
- If you need some helps on git commands, read git - the simple guide
- DRY - Don't repeat yourself
- DOT - Do One Thing
- KISS - Keep It Simple Stupid
- LIM - Less Is More
- English only: codebase, variables, comments...
Focus only on coding, forgot the browser display (next workshop!).
Use console.log or console.table to display results (for the moment)