An introduction to the basics of Webpack

Clément H on Unsplash

Webpack can seem overwhelming and something you might have avoided learning about when building out React applications. But it is pretty simple to set up and create yourself, for you React apps. This will be a beginner’s guide into Webpack and what it’s actually doing. Let’s unpack any questions you might have about Webpack…

We will be going over:

What is Webpack, how does it work, and what is it doing?

If you are familiar with Create React App, Webpack is responsible for the main functionality in Create React App, along with some other things like Babel (a JS compiler). Create…

What is Scope in JavaScript?

Scoping in JavaScript refers to what variables your program has access to at any given moment in time. So let’s start scooping into this scope stuff…

What are the different types of scopes?

By default, when coding in JavaScript, you start in the window scope or the root scope. This is the global scope. This means there is only one global scope in a JS document.

Global Variables

Declaring a variable outside of a function is creating a global variable. Global variables have a global scope. Variables in the global scope can be accessed anywhere else in your program, in any other scope.

Local Variables

Carmen Salas

Software Engineer | NYC | she/her

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store