Javascript pieces of code to make you discover new exciting features, useful tips or anything that will give you a better understanding of the subtleties of JS. This repository serves as a central location for all theses snippets.
- Switch statement vs Object Search
- .map() & .reduce()
- Methods for merging (aka concatenating) arrays
- Using Map() vs Object literals
- Weakmap()
- Sets in ES6
- Promises
- Promises Part 2.
- Promise.all vs Promise.allSettled
- Promise.race
- Proxies Part 1. introduction
- Proxies Part 2. (with Reflect)
- Proxies Part 3. makeReadOnly example
- flat() and flatMap()
- Fun with Emoji!
- Some bizarre things in Javascript
- Breaking in nested loops
- EventEmitter
- How to implement a local EventEmitter? (part 1.)
- How to implement a local EventEmitter? (part 2.)
- Using "_" in numbers for better readability
Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated.
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature
) - Commit your Changes (
git commit -m 'Add some AmazingFeature'
) - Push to the Branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
Distributed under the MIT License. See LICENSE
for more information.
- Carbon - Create and share beautiful images of your source code