Implementing Webpack and AJAX - Create a Newsletter Signup Form with Node.js - Ep. 4

preview_player
Показать описание

In this video, we implement Webpack to bundle all of our scripts into one file, while utilizing AJAX to create a seamless POST request from our browser to the server.

Learn how to do all of this step by step, piece by piece, while taking in some extra tips and tricks along the way.

Timeline:
0:43 - Preparing our server to process a POST request
4:02 - Implementing Webpack
6:40 - Adding jQuery w/ Webpack
7:56 - AJAX 101 / Making the AJAX call w/ jQuery
12:08 - Summary and insight into next video

Beatz:
Immortal Beats - Oh Wee - Creative Commons

Support Chris Courses Through Patreon:
--------------------------------------

Chris Courses Social:
---------------------

Christopher Lis Social:
-----------------------
Рекомендации по теме
Комментарии
Автор

i am getting an extra "dist" folder ?? like "/dist/public/js/build.js" messing up the whole setup what to do ?

kartikeyaagrawal
Автор

Hi I read the comment by brennanburch about
(- output: {
path: path.resolve(__dirname, './public/js/'),
filename:'build.js', -)
but its seem that when I compile the webpack its says it ERROR in Entry Module not found: Error: can't resolve './src
here is what I have written in the
const path = require ('path');
module.export = {
entry: './src/scripts.js',
output: {
path: path.resolve(__dirname, './public/js/'),
filename:'build.js',
},
watch: true
};

markho
Автор

This one was a little more tricky. I got it to work somehow. Webpack at first wasn't working. I also noticed in order for everything to work I had to type in webpack into the terminal every time I made updates to the script.js file.

dec
Автор

Im having an issue in the jquery part. Jquery isn't working. Does anyone know how to fix this?

brianwachira
Автор

Guys did anybody had issue with webpack..

gouthamnataraj
Автор

because its MIME type ('text/html') is not executable, and strict MIME type checking is enabled..Guys please let me know if anybody faced similar issue and found the solution..It would be great help..Thanks in advance..

gouthamnataraj