From the course: Angular: Creating and Hosting a Full-Stack Site
Unlock the full course today
Join today to access over 24,800 courses taught by industry experts.
Errors in hapi using hapi/boom
From the course: Angular: Creating and Hosting a Full-Stack Site
Errors in hapi using hapi/boom
- [Instructor] So we've created two routes on our server so far. And before we continue on to adding a database and other routes, we're going to take a little detour and look at a very important concept when writing back in code, and that's how to work with errors. So Hapi's approach to this topic is a little different than what you might find on a lot of other service side frameworks. And most of it revolves around an NPM package called boom, which we can install in our project by running NPM install at Hapi slash boom, and hit enter. Now, this package is our first experience so far with what's sometimes referred to as the Hapi ecosystem. You see, one of the really nice things about working with Hapi, over other possible frameworks like Express, is that Hapi has a pretty extensive collection of different official modules and plugins that allow us to add in functionality to our server without a whole lot of setup. If…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.