Problem building parcel build function lesson 42 HTML Course part 3

Hi All,

I have been busting my brains trying to figure out what’s causing the issue with using the parcel build index.html function in my code.

I keep getting this error:

:rotating_light: /Users/bethany/Desktop/Moshify/CSS/normalize.css:undefined:undefined: plugin is not a function
at LazyResult.run (/usr/local/lib/node_modules/parcel-bundler/node_modules/postcss/lib/lazy-result.js:288:14)
at LazyResult.asyncTick (/usr/local/lib/node_modules/parcel-bundler/node_modules/postcss/lib/lazy-result.js:212:26)
at /usr/local/lib/node_modules/parcel-bundler/node_modules/postcss/lib/lazy-result.js:254:14
at new Promise ()
at LazyResult.async (/usr/local/lib/node_modules/parcel-bundler/node_modules/postcss/lib/lazy-result.js:250:23)
at LazyResult.then (/usr/local/lib/node_modules/parcel-bundler/node_modules/postcss/lib/lazy-result.js:131:17)

I’ve tried clearing my cache folder through the terminal, upgrading node, npm uninstall parcel
npm install parcel@latest --save-dev, and other thingS and I’ve checked the path on my device for that I have my project in but nothing works please help.

For reference I’ve included a screenshot of the way that I am linking in my stylesheet as mosh showed in the course.

1 Like

Here is my directory

1 Like

Looks like a node modules issue, delete node modules folder then run “npm i” in the console

I deleted the node modules folder and ran npm i and got the following result after doing parcel build index.html :

bethany@Bethanys-MacBook-Pro Moshify % parcel build index.html
:sparkles: Built in 2.84s.

dist/banner@2x.84af0887.png 696.78 KB 71ms
dist/ipad@2x.0f69cdee.png 432.22 KB 63ms
dist/banner.b865dda6.png 242.32 KB 65ms
dist/ipad.bbdd3a9b.png 134.1 KB 63ms
dist/wordpress@2x.dd9f8ba2.jpg 107.58 KB 70ms
dist/banner@2x.6d6314ab.webp 104.72 KB 70ms
dist/wordpress@2x.d9e05d1c.webp 94.98 KB 66ms
dist/support@2x.e80709a4.jpg 76.97 KB 64ms
dist/fast@2x.8dff7e5c.jpg 64.34 KB 70ms
dist/easy@2x.31665d23.jpg 55.57 KB 66ms
dist/wordpress.87235ed8.jpg 51.04 KB 63ms
dist/ipad@2x.bec0ff08.webp 44.79 KB 70ms
dist/support@2x.01d24e23.webp 44.12 KB 70ms
dist/fast@2x.5ba4dac3.webp 43.37 KB 65ms
dist/banner@.1598012b.webp 42.65 KB 63ms
dist/support.72d920c2.jpg 42.13 KB 69ms
dist/fast.f4e3cfb3.jpg 36.14 KB 64ms
dist/wordpress.c5854b7a.webp 34.81 KB 63ms
dist/testimonial.ad9df737.jpg 34.71 KB 63ms
dist/easy.5b7ee720.jpg 32.5 KB 72ms
dist/easy@2x.64ebbcb2.webp 27.67 KB 72ms
dist/styles.6e952aae.css.map 25.72 KB 7ms
dist/sprite.8d8a40f5.svg 22.58 KB 67ms
dist/support.22f42806.webp 21.94 KB 64ms
dist/fast.36029745.webp 20.22 KB 65ms
dist/ipad.b748c1d5.webp 19.81 KB 69ms
dist/easy.01749a24.webp 13.54 KB 67ms
dist/index.html 13.41 KB 31ms
dist/styles.6e952aae.css 11.45 KB 1.71s
dist/normalize.d2eee843.css.map 6.97 KB 18ms
dist/normalize.d2eee843.css 1.74 KB 49ms
dist/snap.6223445c.svg 1.29 KB 69ms
dist/main.e3e58749.js 1.27 KB 57ms
dist/logo.762e26a3.svg 928 B 64ms
dist/main.e3e58749.js.map 552 B 10ms
dist/chevron.c96f8430.svg 472 B 64ms
dist/popular.a6fe98f3.svg 464 B 52ms
dist/tick.626c29a3.svg 348 B 53ms

Is this the correct result? This would be my first time deploying a site, is there a way that i can check to see if it worked?

Yeah it’s a success congratulation’s on your first software build! node modules often gets corrupted cause there are so many files.

If you have live server installed as an extension you could right click the html file in vs code and run live or go read / download the extension. There are a few ways.

1 Like

Thank you so much! Yes, I have the live server extension and the site runs properly when I open it with the live server.

2 Likes