There are 4 types of exports: 1— Named exports (several per module) 2**— Default exports** (one per module)3 — Mixed named & default exports 4**— Cyclical Dependencies** 1. Name exports //------ lib.js ------export const sqrt = Math.sqrt;export function square(x) { return x * x;}export function diag(x, y) { return sqrt(square(x) + square(y));}//------ main.js ------import { square, diag } from 'li
![[es6] import, export, default cheatsheet | HackerNoon](https://cdn-ak-scissors.b.st-hatena.com/image/square/06af01de842f71f81b58f8d3cde45883d3c10eb6/height=288;version=1;width=512/https%3A%2F%2Fhackernoon.imgix.net%2Fhn-images%2F1%2AgUzGiHGJP1r9wSx3OQVvVw.jpeg)