Barrel Pattern A barrel is a way to roll up exports from several modules into a single module. The barrel itself is a module file that re-exports selected exports of other modules. For each folder where we want a common export, we create an file that will contain the exports for every file of the folder.
9 Comments
Sort: