A boilerplate to setup and Practice Modern JavaScript
MIT License
A boilerplate to setup and practice Modern JavaScript
1. Install nodemon
globally for watching for file changes while running the code 🔰 📦
$ npm install -g nodemon # npm i -g nodemon
2. Install all dependencies 🔰 📦
$ yarn install
1. Start watching for file changes 👀
$ yarn run watch # yarn start
2. Start writing modern JavaScript in src/index.js
file 📝
// my-module.js
export const name = 'My Module'
// index.js
import * as myModule from './my-module'
console.log(myModule.name) // 'My Module'
3. Enjoy the output 😂
$ yarn start
My Module
1. Example 1 ⮭
// async-await.js
const prom = new Promise(resolve => {
resolve(`Hello`)
})
const longRun = async () => {
const res = await prom
console.log(res)
}
longRun()
2. Example 2 ⮭
// array-includes.js
const includes3 = [1, 3, 4].includes(3)
console.log(includes3)
Abhisek Pattnaik💻 🎨 📖 💡 |
---|
This project follows the all-contributors specification.
All types of Contributions are Welcome 🙏