From 2cda755c13e3cfd24c96da2d71d2972c53ad0a79 Mon Sep 17 00:00:00 2001 From: mohamedkbx <109092116+mohamedkbx@users.noreply.github.com> Date: Tue, 26 Nov 2024 17:43:02 +0200 Subject: [PATCH] feat: setup entry point for the webpack --- STEP-2.md | 7 +++---- webpack.config.js | 8 ++++---- 2 files changed, 7 insertions(+), 8 deletions(-) diff --git a/STEP-2.md b/STEP-2.md index 0e093112b..a156be908 100644 --- a/STEP-2.md +++ b/STEP-2.md @@ -1,4 +1,4 @@ -# Step 2 - Webpack Entry +# Step 2 - Webpack Entry 1. Webpack is going to create a map of our app dependencies, but to make a map you need to start somewhere. In our webpack config, we can declare a starting point for our app. To do this, we need to add this line to the module.exports of our webpack config @@ -10,9 +10,8 @@ entry: './src/client/index.js', 3. Experiment by running the webpack build script (`$ npm run build`). Take a look at the dist folder that appears after a successful webpack build. - **You have been successful when you see a dist folder in the root of your app** -*Some miscellanious notes:* +_Some miscellanious notes:_ -- If you run webpack build and in your text editor you see the dist folder, but nothing inside it - it might still be working. Some text editors will hide folders or folder contents like ```dist```. Yeah... that one didn't have me second guessing myself for like 20 min... +- If you run webpack build and in your text editor you see the dist folder, but nothing inside it - it might still be working. Some text editors will hide folders or folder contents like `dist`. Yeah... that one didn't have me second guessing myself for like 20 min... diff --git a/webpack.config.js b/webpack.config.js index 206bb558f..eb56013b4 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -1,6 +1,6 @@ -const path = require('path') -const webpack = require('webpack') +const path = require("path"); +const webpack = require("webpack"); module.exports = { - entry: './src/client/index.js', -} + entry: "./src/client/index.js", +};